Browse Source
Merge pull request #8478 from adovh/remove-redundant_test_classes
[3.5.1] removed redundant tests
pull/8500/head
Andrew Shvayka
3 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
151 changed files with
212 additions and
1865 deletions
-
application/src/test/java/org/thingsboard/server/controller/AdminControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/AlarmCommentControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/AlarmControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/AssetControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/AssetProfileControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/AuditLogControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/AuthControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/ComponentDescriptorControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/CustomerControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/DashboardControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/DeviceControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/DeviceProfileControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/EdgeControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/EdgeEventControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/EntityQueryControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/EntityRelationControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/EntityViewControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/HomePageApiTest.java
-
application/src/test/java/org/thingsboard/server/controller/OtaPackageControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/RpcControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/RuleChainControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/TbResourceControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/TelemetryControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/TenantControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/TenantProfileControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/TwoFactorAuthConfigTest.java
-
application/src/test/java/org/thingsboard/server/controller/TwoFactorAuthTest.java
-
application/src/test/java/org/thingsboard/server/controller/UserControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/WebsocketApiTest.java
-
application/src/test/java/org/thingsboard/server/controller/WidgetTypeControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/WidgetsBundleControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/AdminControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/AlarmCommentControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/AlarmControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/AssetControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/AssetProfileControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/AuditLogControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/AuthControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/ComponentDescriptorControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/CustomerControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/DashboardControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/DeviceControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/DeviceProfileControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/EdgeControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/EdgeEventControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/EntityQueryControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/EntityRelationControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/EntityViewControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/HomePageApiSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/OtaPackageControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/RpcControllerTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/RuleChainControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/TbResourceControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/TelemetryControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/TenantControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/TenantProfileControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/TwoFactorAuthConfigSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/TwoFactorAuthSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/UserControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/WebsocketApiSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/WidgetTypeControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/controller/sql/WidgetsBundleControllerSqlTest.java
-
application/src/test/java/org/thingsboard/server/edge/AlarmEdgeTest.java
-
application/src/test/java/org/thingsboard/server/edge/AssetEdgeTest.java
-
application/src/test/java/org/thingsboard/server/edge/AssetProfileEdgeTest.java
-
application/src/test/java/org/thingsboard/server/edge/CustomerEdgeTest.java
-
application/src/test/java/org/thingsboard/server/edge/DashboardEdgeTest.java
-
application/src/test/java/org/thingsboard/server/edge/DeviceEdgeTest.java
-
application/src/test/java/org/thingsboard/server/edge/DeviceProfileEdgeTest.java
-
application/src/test/java/org/thingsboard/server/edge/EdgeTest.java
-
application/src/test/java/org/thingsboard/server/edge/EntityViewEdgeTest.java
-
application/src/test/java/org/thingsboard/server/edge/OtaPackageEdgeTest.java
-
application/src/test/java/org/thingsboard/server/edge/QueueEdgeTest.java
-
application/src/test/java/org/thingsboard/server/edge/RelationEdgeTest.java
-
application/src/test/java/org/thingsboard/server/edge/RuleChainEdgeTest.java
-
application/src/test/java/org/thingsboard/server/edge/TelemetryEdgeTest.java
-
application/src/test/java/org/thingsboard/server/edge/UserEdgeTest.java
-
application/src/test/java/org/thingsboard/server/edge/WidgetEdgeTest.java
-
application/src/test/java/org/thingsboard/server/edge/sql/AlarmEdgeSqlTest.java
-
application/src/test/java/org/thingsboard/server/edge/sql/AssetEdgeSqlTest.java
-
application/src/test/java/org/thingsboard/server/edge/sql/AssetProfileEdgeSqlTest.java
-
application/src/test/java/org/thingsboard/server/edge/sql/CustomerEdgeSqlTest.java
-
application/src/test/java/org/thingsboard/server/edge/sql/DashboardEdgeSqlTest.java
-
application/src/test/java/org/thingsboard/server/edge/sql/DeviceEdgeSqlTest.java
-
application/src/test/java/org/thingsboard/server/edge/sql/DeviceProfileEdgeSqlTest.java
-
application/src/test/java/org/thingsboard/server/edge/sql/EdgeSqlTest.java
-
application/src/test/java/org/thingsboard/server/edge/sql/EntityViewEdgeSqlTest.java
-
application/src/test/java/org/thingsboard/server/edge/sql/OtaPackageEdgeSqlTest.java
-
application/src/test/java/org/thingsboard/server/edge/sql/QueueEdgeSqlTest.java
-
application/src/test/java/org/thingsboard/server/edge/sql/RelationEdgeSqlTest.java
-
application/src/test/java/org/thingsboard/server/edge/sql/RuleChainEdgeSqlTest.java
-
application/src/test/java/org/thingsboard/server/edge/sql/TelemetryEdgeSqlTest.java
-
application/src/test/java/org/thingsboard/server/edge/sql/UserEdgeSqlTest.java
-
application/src/test/java/org/thingsboard/server/edge/sql/WidgetEdgeSqlTest.java
-
dao/src/test/java/org/thingsboard/server/dao/service/AdminSettingsServiceTest.java
-
dao/src/test/java/org/thingsboard/server/dao/service/AlarmCommentServiceTest.java
-
dao/src/test/java/org/thingsboard/server/dao/service/AlarmServiceTest.java
-
dao/src/test/java/org/thingsboard/server/dao/service/ApiUsageStateServiceTest.java
-
dao/src/test/java/org/thingsboard/server/dao/service/AssetProfileServiceTest.java
-
dao/src/test/java/org/thingsboard/server/dao/service/AssetServiceTest.java
|
|
|
@ -24,6 +24,7 @@ import org.mockito.Mockito; |
|
|
|
import org.thingsboard.common.util.JacksonUtil; |
|
|
|
import org.thingsboard.server.common.data.AdminSettings; |
|
|
|
import org.thingsboard.server.common.data.security.model.JwtSettings; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import java.nio.charset.StandardCharsets; |
|
|
|
import java.util.Base64; |
|
|
|
@ -39,7 +40,8 @@ import static org.springframework.test.web.servlet.result.MockMvcResultMatchers. |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
@Slf4j |
|
|
|
public abstract class BaseAdminControllerTest extends AbstractControllerTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class AdminControllerTest extends AbstractControllerTest { |
|
|
|
final JwtSettings defaultJwtSettings = new JwtSettings(9000, 604800, "thingsboard.io", "thingsboardDefaultSigningKey"); |
|
|
|
|
|
|
|
@Test |
|
|
|
@ -40,6 +40,7 @@ import org.thingsboard.server.common.data.audit.ActionType; |
|
|
|
import org.thingsboard.server.common.data.id.AlarmId; |
|
|
|
import org.thingsboard.server.common.data.page.PageData; |
|
|
|
import org.thingsboard.server.dao.alarm.AlarmDao; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import java.util.LinkedList; |
|
|
|
import java.util.List; |
|
|
|
@ -48,8 +49,9 @@ import static org.hamcrest.Matchers.containsString; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
@Slf4j |
|
|
|
@ContextConfiguration(classes = {BaseAlarmCommentControllerTest.Config.class}) |
|
|
|
public abstract class BaseAlarmCommentControllerTest extends AbstractControllerTest { |
|
|
|
@ContextConfiguration(classes = {AlarmCommentControllerTest.Config.class}) |
|
|
|
@DaoSqlTest |
|
|
|
public class AlarmCommentControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
protected Device customerDevice; |
|
|
|
protected Alarm alarm; |
|
|
|
@ -40,6 +40,7 @@ import org.thingsboard.server.common.data.audit.ActionType; |
|
|
|
import org.thingsboard.server.common.data.id.AlarmId; |
|
|
|
import org.thingsboard.server.common.data.page.PageData; |
|
|
|
import org.thingsboard.server.dao.alarm.AlarmDao; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import java.util.LinkedList; |
|
|
|
import java.util.List; |
|
|
|
@ -48,8 +49,9 @@ import static org.hamcrest.Matchers.containsString; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
@Slf4j |
|
|
|
@ContextConfiguration(classes = {BaseAlarmControllerTest.Config.class}) |
|
|
|
public abstract class BaseAlarmControllerTest extends AbstractControllerTest { |
|
|
|
@ContextConfiguration(classes = {AlarmControllerTest.Config.class}) |
|
|
|
@DaoSqlTest |
|
|
|
public class AlarmControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
public static final String TEST_ALARM_TYPE = "Test"; |
|
|
|
|
|
|
|
@ -46,6 +46,7 @@ import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.dao.asset.AssetDao; |
|
|
|
import org.thingsboard.server.dao.exception.DataValidationException; |
|
|
|
import org.thingsboard.server.dao.model.ModelConstants; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.service.stats.DefaultRuleEngineStatisticsService; |
|
|
|
|
|
|
|
import java.util.ArrayList; |
|
|
|
@ -56,8 +57,9 @@ import static org.hamcrest.Matchers.containsString; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
import static org.thingsboard.server.dao.model.ModelConstants.NULL_UUID; |
|
|
|
|
|
|
|
@ContextConfiguration(classes = {BaseAssetControllerTest.Config.class}) |
|
|
|
public abstract class BaseAssetControllerTest extends AbstractControllerTest { |
|
|
|
@ContextConfiguration(classes = {AssetControllerTest.Config.class}) |
|
|
|
@DaoSqlTest |
|
|
|
public class AssetControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
private IdComparator<Asset> idComparator = new IdComparator<>(); |
|
|
|
|
|
|
|
@ -42,6 +42,7 @@ import org.thingsboard.server.common.data.rule.RuleChain; |
|
|
|
import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.dao.asset.AssetProfileDao; |
|
|
|
import org.thingsboard.server.dao.exception.DataValidationException; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import java.util.ArrayList; |
|
|
|
import java.util.Collections; |
|
|
|
@ -51,8 +52,9 @@ import java.util.stream.Collectors; |
|
|
|
import static org.hamcrest.Matchers.containsString; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
@ContextConfiguration(classes = {BaseAssetProfileControllerTest.Config.class}) |
|
|
|
public abstract class BaseAssetProfileControllerTest extends AbstractControllerTest { |
|
|
|
@ContextConfiguration(classes = {AssetProfileControllerTest.Config.class}) |
|
|
|
@DaoSqlTest |
|
|
|
public class AssetProfileControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
private IdComparator<AssetProfile> idComparator = new IdComparator<>(); |
|
|
|
private IdComparator<AssetProfileInfo> assetProfileInfoIdComparator = new IdComparator<>(); |
|
|
|
@ -34,6 +34,7 @@ import org.thingsboard.server.common.data.page.TimePageLink; |
|
|
|
import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.dao.audit.AuditLogDao; |
|
|
|
import org.thingsboard.server.dao.model.ModelConstants; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.dao.sqlts.insert.sql.SqlPartitioningRepository; |
|
|
|
import org.thingsboard.server.service.ttl.AuditLogsCleanUpService; |
|
|
|
|
|
|
|
@ -50,7 +51,8 @@ import static org.mockito.Mockito.reset; |
|
|
|
import static org.mockito.Mockito.verify; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
public abstract class BaseAuditLogControllerTest extends AbstractControllerTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class AuditLogControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
private Tenant savedTenant; |
|
|
|
private User tenantAdmin; |
|
|
|
@ -17,6 +17,7 @@ package org.thingsboard.server.controller; |
|
|
|
|
|
|
|
import org.junit.Test; |
|
|
|
import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import java.util.concurrent.TimeUnit; |
|
|
|
|
|
|
|
@ -24,7 +25,8 @@ import static org.hamcrest.Matchers.is; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.jsonPath; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
public abstract class BaseAuthControllerTest extends AbstractControllerTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class AuthControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
@Test |
|
|
|
public void testGetUser() throws Exception { |
|
|
|
@ -28,12 +28,14 @@ import org.thingsboard.server.common.data.plugin.ComponentScope; |
|
|
|
import org.thingsboard.server.common.data.plugin.ComponentType; |
|
|
|
import org.thingsboard.server.common.data.rule.RuleChainType; |
|
|
|
import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import java.util.List; |
|
|
|
|
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
public abstract class BaseComponentDescriptorControllerTest extends AbstractControllerTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class ComponentDescriptorControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
private static final int AMOUNT_OF_DEFAULT_FILTER_NODES = 4; |
|
|
|
private Tenant savedTenant; |
|
|
|
@ -44,6 +44,7 @@ import org.thingsboard.server.common.data.page.PageLink; |
|
|
|
import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.dao.customer.CustomerDao; |
|
|
|
import org.thingsboard.server.dao.exception.DataValidationException; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import java.util.ArrayList; |
|
|
|
import java.util.List; |
|
|
|
@ -53,8 +54,9 @@ import static org.assertj.core.api.Assertions.assertThat; |
|
|
|
import static org.hamcrest.Matchers.containsString; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
@ContextConfiguration(classes = {BaseCustomerControllerTest.Config.class}) |
|
|
|
public abstract class BaseCustomerControllerTest extends AbstractControllerTest { |
|
|
|
@ContextConfiguration(classes = {CustomerControllerTest.Config.class}) |
|
|
|
@DaoSqlTest |
|
|
|
public class CustomerControllerTest extends AbstractControllerTest { |
|
|
|
static final TypeReference<PageData<Customer>> PAGE_DATA_CUSTOMER_TYPE_REFERENCE = new TypeReference<>() { |
|
|
|
}; |
|
|
|
|
|
|
|
@ -43,6 +43,7 @@ import org.thingsboard.server.common.data.page.PageLink; |
|
|
|
import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.dao.dashboard.DashboardDao; |
|
|
|
import org.thingsboard.server.dao.exception.DataValidationException; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import java.util.ArrayList; |
|
|
|
import java.util.Collections; |
|
|
|
@ -51,8 +52,9 @@ import java.util.List; |
|
|
|
import static org.hamcrest.Matchers.containsString; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
@ContextConfiguration(classes = {BaseDashboardControllerTest.Config.class}) |
|
|
|
public abstract class BaseDashboardControllerTest extends AbstractControllerTest { |
|
|
|
@ContextConfiguration(classes = {DashboardControllerTest.Config.class}) |
|
|
|
@DaoSqlTest |
|
|
|
public class DashboardControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
private IdComparator<DashboardInfo> idComparator = new IdComparator<>(); |
|
|
|
|
|
|
|
@ -68,6 +68,7 @@ import org.thingsboard.server.dao.device.DeviceDao; |
|
|
|
import org.thingsboard.server.dao.exception.DataValidationException; |
|
|
|
import org.thingsboard.server.dao.exception.DeviceCredentialsValidationException; |
|
|
|
import org.thingsboard.server.dao.model.ModelConstants; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.service.gateway_device.GatewayNotificationsService; |
|
|
|
|
|
|
|
import java.util.ArrayList; |
|
|
|
@ -84,8 +85,9 @@ import static org.thingsboard.server.common.data.ota.OtaPackageType.FIRMWARE; |
|
|
|
import static org.thingsboard.server.common.data.ota.OtaPackageType.SOFTWARE; |
|
|
|
import static org.thingsboard.server.dao.model.ModelConstants.NULL_UUID; |
|
|
|
|
|
|
|
@ContextConfiguration(classes = {BaseDeviceControllerTest.Config.class}) |
|
|
|
public abstract class BaseDeviceControllerTest extends AbstractControllerTest { |
|
|
|
@ContextConfiguration(classes = {DeviceControllerTest.Config.class}) |
|
|
|
@DaoSqlTest |
|
|
|
public class DeviceControllerTest extends AbstractControllerTest { |
|
|
|
static final TypeReference<PageData<Device>> PAGE_DATA_DEVICE_TYPE_REF = new TypeReference<>() { |
|
|
|
}; |
|
|
|
|
|
|
|
@ -51,6 +51,7 @@ import org.thingsboard.server.common.data.rule.RuleChain; |
|
|
|
import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.dao.device.DeviceProfileDao; |
|
|
|
import org.thingsboard.server.dao.exception.DataValidationException; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import java.util.ArrayList; |
|
|
|
import java.util.Collections; |
|
|
|
@ -62,8 +63,9 @@ import static org.springframework.test.web.servlet.result.MockMvcResultMatchers. |
|
|
|
import static org.thingsboard.server.common.data.ota.OtaPackageType.FIRMWARE; |
|
|
|
import static org.thingsboard.server.common.data.ota.OtaPackageType.SOFTWARE; |
|
|
|
|
|
|
|
@ContextConfiguration(classes = {BaseDeviceProfileControllerTest.Config.class}) |
|
|
|
public abstract class BaseDeviceProfileControllerTest extends AbstractControllerTest { |
|
|
|
@ContextConfiguration(classes = {DeviceProfileControllerTest.Config.class}) |
|
|
|
@DaoSqlTest |
|
|
|
public class DeviceProfileControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
private IdComparator<DeviceProfile> idComparator = new IdComparator<>(); |
|
|
|
private IdComparator<DeviceProfileInfo> deviceProfileInfoIdComparator = new IdComparator<>(); |
|
|
|
@ -52,6 +52,7 @@ import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.dao.edge.EdgeDao; |
|
|
|
import org.thingsboard.server.dao.exception.DataValidationException; |
|
|
|
import org.thingsboard.server.dao.model.ModelConstants; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.edge.imitator.EdgeImitator; |
|
|
|
import org.thingsboard.server.gen.edge.v1.AdminSettingsUpdateMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.AssetProfileUpdateMsg; |
|
|
|
@ -77,8 +78,9 @@ import static org.thingsboard.server.dao.model.ModelConstants.NULL_UUID; |
|
|
|
@TestPropertySource(properties = { |
|
|
|
"edges.enabled=true", |
|
|
|
}) |
|
|
|
@ContextConfiguration(classes = {BaseEdgeControllerTest.Config.class}) |
|
|
|
public abstract class BaseEdgeControllerTest extends AbstractControllerTest { |
|
|
|
@ContextConfiguration(classes = {EdgeControllerTest.Config.class}) |
|
|
|
@DaoSqlTest |
|
|
|
public class EdgeControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
public static final String EDGE_HOST = "localhost"; |
|
|
|
public static final int EDGE_PORT = 7070; |
|
|
|
@ -40,6 +40,7 @@ import org.thingsboard.server.common.data.page.TimePageLink; |
|
|
|
import org.thingsboard.server.common.data.relation.EntityRelation; |
|
|
|
import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.dao.edge.EdgeEventDao; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.dao.sqlts.insert.sql.SqlPartitioningRepository; |
|
|
|
import org.thingsboard.server.service.ttl.EdgeEventsCleanUpService; |
|
|
|
|
|
|
|
@ -59,7 +60,8 @@ import static org.springframework.test.web.servlet.result.MockMvcResultMatchers. |
|
|
|
"edges.enabled=true", |
|
|
|
}) |
|
|
|
@Slf4j |
|
|
|
public abstract class BaseEdgeEventControllerTest extends AbstractControllerTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class EdgeEventControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
private Tenant savedTenant; |
|
|
|
private User tenantAdmin; |
|
|
|
@ -52,6 +52,7 @@ import org.thingsboard.server.common.data.query.KeyFilter; |
|
|
|
import org.thingsboard.server.common.data.query.NumericFilterPredicate; |
|
|
|
import org.thingsboard.server.common.data.query.TsValue; |
|
|
|
import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import java.util.ArrayList; |
|
|
|
import java.util.Collections; |
|
|
|
@ -62,7 +63,8 @@ import java.util.stream.Collectors; |
|
|
|
import static org.assertj.core.api.Assertions.assertThat; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
public abstract class BaseEntityQueryControllerTest extends AbstractControllerTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class EntityQueryControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
private Tenant savedTenant; |
|
|
|
private User tenantAdmin; |
|
|
|
@ -41,6 +41,7 @@ import org.thingsboard.server.common.data.relation.RelationTypeGroup; |
|
|
|
import org.thingsboard.server.common.data.relation.RelationsSearchParameters; |
|
|
|
import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.dao.relation.RelationService; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import java.util.Collections; |
|
|
|
import java.util.List; |
|
|
|
@ -50,7 +51,8 @@ import static org.hamcrest.Matchers.containsString; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
@Slf4j |
|
|
|
public abstract class BaseEntityRelationControllerTest extends AbstractControllerTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class EntityRelationControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
public static final String BASE_DEVICE_NAME = "Test dummy device"; |
|
|
|
|
|
|
|
@ -64,6 +64,7 @@ import org.thingsboard.server.common.data.security.DeviceCredentials; |
|
|
|
import org.thingsboard.server.dao.entityview.EntityViewDao; |
|
|
|
import org.thingsboard.server.dao.exception.DataValidationException; |
|
|
|
import org.thingsboard.server.dao.model.ModelConstants; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import java.util.ArrayList; |
|
|
|
import java.util.HashSet; |
|
|
|
@ -89,8 +90,9 @@ import static org.thingsboard.server.dao.model.ModelConstants.NULL_UUID; |
|
|
|
"js.evaluator=mock", |
|
|
|
}) |
|
|
|
@Slf4j |
|
|
|
@ContextConfiguration(classes = {BaseEntityViewControllerTest.Config.class}) |
|
|
|
public abstract class BaseEntityViewControllerTest extends AbstractControllerTest { |
|
|
|
@ContextConfiguration(classes = {EntityViewControllerTest.Config.class}) |
|
|
|
@DaoSqlTest |
|
|
|
public class EntityViewControllerTest extends AbstractControllerTest { |
|
|
|
static final TypeReference<PageData<EntityView>> PAGE_DATA_ENTITY_VIEW_TYPE_REF = new TypeReference<>() { |
|
|
|
}; |
|
|
|
static final TypeReference<PageData<EntityViewInfo>> PAGE_DATA_ENTITY_VIEW_INFO_TYPE_REF = new TypeReference<>() { |
|
|
|
@ -57,6 +57,7 @@ import org.thingsboard.server.common.data.query.TsValue; |
|
|
|
import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.common.data.tenant.profile.DefaultTenantProfileConfiguration; |
|
|
|
import org.thingsboard.server.common.stats.TbApiUsageStateClient; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.dao.settings.AdminSettingsService; |
|
|
|
import org.thingsboard.server.dao.tenant.TbTenantProfileCache; |
|
|
|
import org.thingsboard.server.service.ws.telemetry.cmd.v2.EntityCountCmd; |
|
|
|
@ -73,7 +74,8 @@ import java.util.concurrent.TimeUnit; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
@Slf4j |
|
|
|
public abstract class BaseHomePageApiTest extends AbstractControllerTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class HomePageApiTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
@Autowired |
|
|
|
private TbApiUsageStateClient apiUsageStateClient; |
|
|
|
@ -38,6 +38,7 @@ import org.thingsboard.server.common.data.page.PageData; |
|
|
|
import org.thingsboard.server.common.data.page.PageLink; |
|
|
|
import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.dao.exception.DataValidationException; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import java.nio.ByteBuffer; |
|
|
|
import java.util.ArrayList; |
|
|
|
@ -48,7 +49,8 @@ import static org.hamcrest.Matchers.containsString; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
import static org.thingsboard.server.common.data.ota.OtaPackageType.FIRMWARE; |
|
|
|
|
|
|
|
public abstract class BaseOtaPackageControllerTest extends AbstractControllerTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class OtaPackageControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
private IdComparator<OtaPackageInfo> idComparator = new IdComparator<>(); |
|
|
|
|
|
|
|
@ -31,12 +31,14 @@ import org.thingsboard.server.common.data.page.PageData; |
|
|
|
import org.thingsboard.server.common.data.rpc.Rpc; |
|
|
|
import org.thingsboard.server.common.data.rpc.RpcStatus; |
|
|
|
import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import java.util.List; |
|
|
|
|
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
public abstract class BaseRpcControllerTest extends AbstractControllerTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class RpcControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
private Tenant savedTenant; |
|
|
|
private User tenantAdmin; |
|
|
|
@ -44,6 +44,7 @@ import org.thingsboard.server.common.data.rule.RuleNode; |
|
|
|
import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.dao.exception.DataValidationException; |
|
|
|
import org.thingsboard.server.dao.rule.RuleChainDao; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import java.util.ArrayList; |
|
|
|
import java.util.Collections; |
|
|
|
@ -53,8 +54,9 @@ import static org.assertj.core.api.Assertions.assertThat; |
|
|
|
import static org.hamcrest.Matchers.containsString; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
@ContextConfiguration(classes = {BaseRuleChainControllerTest.Config.class}) |
|
|
|
public abstract class BaseRuleChainControllerTest extends AbstractControllerTest { |
|
|
|
@ContextConfiguration(classes = {RuleChainControllerTest.Config.class}) |
|
|
|
@DaoSqlTest |
|
|
|
public class RuleChainControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
private IdComparator<RuleChain> idComparator = new IdComparator<>(); |
|
|
|
|
|
|
|
@ -32,6 +32,7 @@ import org.thingsboard.server.common.data.page.PageData; |
|
|
|
import org.thingsboard.server.common.data.page.PageLink; |
|
|
|
import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.dao.exception.DataValidationException; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import java.util.ArrayList; |
|
|
|
import java.util.Collections; |
|
|
|
@ -40,7 +41,8 @@ import java.util.List; |
|
|
|
import static org.hamcrest.Matchers.containsString; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
public abstract class BaseTbResourceControllerTest extends AbstractControllerTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class TbResourceControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
private IdComparator<TbResourceInfo> idComparator = new IdComparator<>(); |
|
|
|
|
|
|
|
@ -20,10 +20,12 @@ import org.thingsboard.server.common.data.Device; |
|
|
|
import org.thingsboard.server.common.data.SaveDeviceWithCredentialsRequest; |
|
|
|
import org.thingsboard.server.common.data.security.DeviceCredentials; |
|
|
|
import org.thingsboard.server.common.data.security.DeviceCredentialsType; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
public abstract class BaseTelemetryControllerTest extends AbstractControllerTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class TelemetryControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
@Test |
|
|
|
public void testConstraintValidator() throws Exception { |
|
|
|
@ -49,6 +49,7 @@ import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.common.data.tenant.profile.DefaultTenantProfileConfiguration; |
|
|
|
import org.thingsboard.server.common.data.tenant.profile.TenantProfileData; |
|
|
|
import org.thingsboard.server.common.data.tenant.profile.TenantProfileQueueConfiguration; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import java.util.ArrayList; |
|
|
|
import java.util.Comparator; |
|
|
|
@ -69,7 +70,8 @@ import static org.springframework.test.web.servlet.result.MockMvcResultMatchers. |
|
|
|
"js.evaluator=mock", |
|
|
|
}) |
|
|
|
@Slf4j |
|
|
|
public abstract class BaseTenantControllerTest extends AbstractControllerTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class TenantControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
static final TypeReference<PageData<Tenant>> PAGE_DATA_TENANT_TYPE_REF = new TypeReference<>() { |
|
|
|
}; |
|
|
|
@ -36,6 +36,7 @@ import org.thingsboard.server.common.data.queue.SubmitStrategyType; |
|
|
|
import org.thingsboard.server.common.data.tenant.profile.DefaultTenantProfileConfiguration; |
|
|
|
import org.thingsboard.server.common.data.tenant.profile.TenantProfileData; |
|
|
|
import org.thingsboard.server.common.data.tenant.profile.TenantProfileQueueConfiguration; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import java.util.ArrayList; |
|
|
|
import java.util.Collections; |
|
|
|
@ -47,7 +48,8 @@ import static org.mockito.Mockito.never; |
|
|
|
import static org.mockito.Mockito.times; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
public abstract class BaseTenantProfileControllerTest extends AbstractControllerTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class TenantProfileControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
private IdComparator<TenantProfile> idComparator = new IdComparator<>(); |
|
|
|
private IdComparator<EntityInfo> tenantProfileInfoIdComparator = new IdComparator<>(); |
|
|
|
@ -39,6 +39,7 @@ import org.thingsboard.server.common.data.security.model.mfa.provider.SmsTwoFaPr |
|
|
|
import org.thingsboard.server.common.data.security.model.mfa.provider.TotpTwoFaProviderConfig; |
|
|
|
import org.thingsboard.server.common.data.security.model.mfa.provider.TwoFaProviderConfig; |
|
|
|
import org.thingsboard.server.common.data.security.model.mfa.provider.TwoFaProviderType; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.service.security.auth.mfa.TwoFactorAuthService; |
|
|
|
import org.thingsboard.server.service.security.auth.mfa.config.TwoFaConfigManager; |
|
|
|
import org.thingsboard.server.service.security.auth.mfa.provider.impl.OtpBasedTwoFaProvider; |
|
|
|
@ -58,7 +59,8 @@ import static org.mockito.Mockito.doNothing; |
|
|
|
import static org.mockito.Mockito.verify; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
public abstract class TwoFactorAuthConfigTest extends AbstractControllerTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class TwoFactorAuthConfigTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
@SpyBean |
|
|
|
private TotpTwoFaProvider totpTwoFactorAuthProvider; |
|
|
|
|
|
|
|
@ -48,6 +48,7 @@ import org.thingsboard.server.common.data.security.model.mfa.provider.TotpTwoFaP |
|
|
|
import org.thingsboard.server.common.data.security.model.mfa.provider.TwoFaProviderConfig; |
|
|
|
import org.thingsboard.server.common.data.security.model.mfa.provider.TwoFaProviderType; |
|
|
|
import org.thingsboard.server.dao.audit.AuditLogService; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.dao.user.UserService; |
|
|
|
import org.thingsboard.server.service.security.auth.mfa.TwoFactorAuthService; |
|
|
|
import org.thingsboard.server.service.security.auth.mfa.config.TwoFaConfigManager; |
|
|
|
@ -72,7 +73,8 @@ import static org.mockito.Mockito.doNothing; |
|
|
|
import static org.mockito.Mockito.verify; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
public abstract class TwoFactorAuthTest extends AbstractControllerTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class TwoFactorAuthTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
@Autowired |
|
|
|
private TwoFaConfigManager twoFaConfigManager; |
|
|
|
|
|
|
|
@ -50,6 +50,7 @@ import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.common.data.settings.StarredDashboardInfo; |
|
|
|
import org.thingsboard.server.common.data.settings.UserDashboardsInfo; |
|
|
|
import org.thingsboard.server.dao.exception.DataValidationException; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.dao.user.UserDao; |
|
|
|
|
|
|
|
import java.util.ArrayList; |
|
|
|
@ -66,8 +67,9 @@ import static org.springframework.test.web.servlet.result.MockMvcResultMatchers. |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
import static org.thingsboard.server.dao.model.ModelConstants.SYSTEM_TENANT; |
|
|
|
|
|
|
|
@ContextConfiguration(classes = {BaseUserControllerTest.Config.class}) |
|
|
|
public abstract class BaseUserControllerTest extends AbstractControllerTest { |
|
|
|
@ContextConfiguration(classes = {UserControllerTest.Config.class}) |
|
|
|
@DaoSqlTest |
|
|
|
public class UserControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
private IdComparator<User> idComparator = new IdComparator<>(); |
|
|
|
private IdComparator<UserEmailInfo> userDataIdComparator = new IdComparator<>(); |
|
|
|
@ -53,6 +53,7 @@ import org.thingsboard.server.common.data.query.KeyFilter; |
|
|
|
import org.thingsboard.server.common.data.query.NumericFilterPredicate; |
|
|
|
import org.thingsboard.server.common.data.query.SingleEntityFilter; |
|
|
|
import org.thingsboard.server.common.data.query.TsValue; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.service.subscription.SubscriptionErrorCode; |
|
|
|
import org.thingsboard.server.service.subscription.TbAttributeSubscriptionScope; |
|
|
|
import org.thingsboard.server.service.telemetry.TelemetrySubscriptionService; |
|
|
|
@ -73,7 +74,8 @@ import static org.assertj.core.api.Assertions.assertThatNoException; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
@Slf4j |
|
|
|
public abstract class BaseWebsocketApiTest extends AbstractControllerTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class WebsocketApiTest extends AbstractControllerTest { |
|
|
|
@Autowired |
|
|
|
private TelemetrySubscriptionService tsService; |
|
|
|
|
|
|
|
@ -28,6 +28,7 @@ import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.common.data.widget.WidgetType; |
|
|
|
import org.thingsboard.server.common.data.widget.WidgetTypeDetails; |
|
|
|
import org.thingsboard.server.common.data.widget.WidgetsBundle; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import java.util.ArrayList; |
|
|
|
import java.util.Collections; |
|
|
|
@ -36,7 +37,8 @@ import java.util.List; |
|
|
|
import static org.hamcrest.Matchers.containsString; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
public abstract class BaseWidgetTypeControllerTest extends AbstractControllerTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class WidgetTypeControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
private IdComparator<WidgetType> idComparator = new IdComparator<>(); |
|
|
|
|
|
|
|
@ -31,6 +31,7 @@ import org.thingsboard.server.common.data.page.PageData; |
|
|
|
import org.thingsboard.server.common.data.page.PageLink; |
|
|
|
import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.common.data.widget.WidgetsBundle; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
import java.util.ArrayList; |
|
|
|
import java.util.Collections; |
|
|
|
@ -40,7 +41,8 @@ import static org.hamcrest.Matchers.containsString; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
import static org.thingsboard.server.dao.model.ModelConstants.SYSTEM_TENANT; |
|
|
|
|
|
|
|
public abstract class BaseWidgetsBundleControllerTest extends AbstractControllerTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class WidgetsBundleControllerTest extends AbstractControllerTest { |
|
|
|
|
|
|
|
private IdComparator<WidgetsBundle> idComparator = new IdComparator<>(); |
|
|
|
|
|
|
|
@ -1,26 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseAdminControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
/** |
|
|
|
* Created by Valerii Sosliuk on 6/28/2017. |
|
|
|
*/ |
|
|
|
@DaoSqlTest |
|
|
|
public class AdminControllerSqlTest extends BaseAdminControllerTest { |
|
|
|
} |
|
|
|
@ -1,23 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseAlarmCommentControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class AlarmCommentControllerSqlTest extends BaseAlarmCommentControllerTest { |
|
|
|
} |
|
|
|
@ -1,23 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseAlarmControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class AlarmControllerSqlTest extends BaseAlarmControllerTest { |
|
|
|
} |
|
|
|
@ -1,26 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseAssetControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
/** |
|
|
|
* Created by Valerii Sosliuk on 6/28/2017. |
|
|
|
*/ |
|
|
|
@DaoSqlTest |
|
|
|
public class AssetControllerSqlTest extends BaseAssetControllerTest { |
|
|
|
} |
|
|
|
@ -1,23 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseAssetProfileControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class AssetProfileControllerSqlTest extends BaseAssetProfileControllerTest { |
|
|
|
} |
|
|
|
@ -1,23 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseAuditLogControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class AuditLogControllerSqlTest extends BaseAuditLogControllerTest { |
|
|
|
} |
|
|
|
@ -1,26 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseAuthControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
/** |
|
|
|
* Created by Valerii Sosliuk on 6/28/2017. |
|
|
|
*/ |
|
|
|
@DaoSqlTest |
|
|
|
public class AuthControllerSqlTest extends BaseAuthControllerTest { |
|
|
|
} |
|
|
|
@ -1,23 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseComponentDescriptorControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class ComponentDescriptorControllerSqlTest extends BaseComponentDescriptorControllerTest { |
|
|
|
} |
|
|
|
@ -1,26 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseCustomerControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
/** |
|
|
|
* Created by Valerii Sosliuk on 6/28/2017. |
|
|
|
*/ |
|
|
|
@DaoSqlTest |
|
|
|
public class CustomerControllerSqlTest extends BaseCustomerControllerTest { |
|
|
|
} |
|
|
|
@ -1,26 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseDashboardControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
/** |
|
|
|
* Created by Valerii Sosliuk on 6/28/2017. |
|
|
|
*/ |
|
|
|
@DaoSqlTest |
|
|
|
public class DashboardControllerSqlTest extends BaseDashboardControllerTest { |
|
|
|
} |
|
|
|
@ -1,26 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseDeviceControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
/** |
|
|
|
* Created by Valerii Sosliuk on 6/28/2017. |
|
|
|
*/ |
|
|
|
@DaoSqlTest |
|
|
|
public class DeviceControllerSqlTest extends BaseDeviceControllerTest { |
|
|
|
} |
|
|
|
@ -1,23 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseDeviceProfileControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class DeviceProfileControllerSqlTest extends BaseDeviceProfileControllerTest { |
|
|
|
} |
|
|
|
@ -1,23 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseEdgeControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class EdgeControllerSqlTest extends BaseEdgeControllerTest { |
|
|
|
} |
|
|
|
@ -1,23 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseEdgeEventControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class EdgeEventControllerSqlTest extends BaseEdgeEventControllerTest { |
|
|
|
} |
|
|
|
@ -1,23 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseEntityQueryControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class EntityQueryControllerSqlTest extends BaseEntityQueryControllerTest { |
|
|
|
} |
|
|
|
@ -1,23 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseEntityRelationControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class EntityRelationControllerSqlTest extends BaseEntityRelationControllerTest { |
|
|
|
} |
|
|
|
@ -1,26 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseEntityViewControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
/** |
|
|
|
* Created by Victor Basanets on 8/27/2017. |
|
|
|
*/ |
|
|
|
@DaoSqlTest |
|
|
|
public class EntityViewControllerSqlTest extends BaseEntityViewControllerTest { |
|
|
|
} |
|
|
|
@ -1,23 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseHomePageApiTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class HomePageApiSqlTest extends BaseHomePageApiTest { |
|
|
|
} |
|
|
|
@ -1,23 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseOtaPackageControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class OtaPackageControllerSqlTest extends BaseOtaPackageControllerTest { |
|
|
|
} |
|
|
|
@ -1,23 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseRpcControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class RpcControllerTest extends BaseRpcControllerTest { |
|
|
|
} |
|
|
|
@ -1,23 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseRuleChainControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class RuleChainControllerSqlTest extends BaseRuleChainControllerTest { |
|
|
|
} |
|
|
|
@ -1,23 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseTbResourceControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class TbResourceControllerSqlTest extends BaseTbResourceControllerTest { |
|
|
|
} |
|
|
|
@ -1,23 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseTelemetryControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class TelemetryControllerSqlTest extends BaseTelemetryControllerTest { |
|
|
|
} |
|
|
|
@ -1,26 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseTenantControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
/** |
|
|
|
* Created by Valerii Sosliuk on 6/28/2017. |
|
|
|
*/ |
|
|
|
@DaoSqlTest |
|
|
|
public class TenantControllerSqlTest extends BaseTenantControllerTest { |
|
|
|
} |
|
|
|
@ -1,23 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseTenantProfileControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class TenantProfileControllerSqlTest extends BaseTenantProfileControllerTest { |
|
|
|
} |
|
|
|
@ -1,23 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.TwoFactorAuthConfigTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class TwoFactorAuthConfigSqlTest extends TwoFactorAuthConfigTest { |
|
|
|
} |
|
|
|
@ -1,23 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.TwoFactorAuthTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class TwoFactorAuthSqlTest extends TwoFactorAuthTest { |
|
|
|
} |
|
|
|
@ -1,26 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseUserControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
/** |
|
|
|
* Created by Valerii Sosliuk on 6/28/2017. |
|
|
|
*/ |
|
|
|
@DaoSqlTest |
|
|
|
public class UserControllerSqlTest extends BaseUserControllerTest { |
|
|
|
} |
|
|
|
@ -1,23 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseWebsocketApiTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class WebsocketApiSqlTest extends BaseWebsocketApiTest { |
|
|
|
} |
|
|
|
@ -1,26 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseWidgetTypeControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
/** |
|
|
|
* Created by Valerii Sosliuk on 6/28/2017. |
|
|
|
*/ |
|
|
|
@DaoSqlTest |
|
|
|
public class WidgetTypeControllerSqlTest extends BaseWidgetTypeControllerTest { |
|
|
|
} |
|
|
|
@ -1,26 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.controller.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.controller.BaseWidgetsBundleControllerTest; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
|
|
|
|
/** |
|
|
|
* Created by Valerii Sosliuk on 6/28/2017. |
|
|
|
*/ |
|
|
|
@DaoSqlTest |
|
|
|
public class WidgetsBundleControllerSqlTest extends BaseWidgetsBundleControllerTest { |
|
|
|
} |
|
|
|
@ -29,6 +29,7 @@ import org.thingsboard.server.common.data.alarm.AlarmStatus; |
|
|
|
import org.thingsboard.server.common.data.id.AlarmId; |
|
|
|
import org.thingsboard.server.common.data.page.PageData; |
|
|
|
import org.thingsboard.server.common.data.page.PageLink; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.gen.edge.v1.AlarmUpdateMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.UpdateMsgType; |
|
|
|
import org.thingsboard.server.gen.edge.v1.UplinkMsg; |
|
|
|
@ -39,7 +40,8 @@ import java.util.UUID; |
|
|
|
|
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
abstract public class BaseAlarmEdgeTest extends AbstractEdgeTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class AlarmEdgeTest extends AbstractEdgeTest { |
|
|
|
|
|
|
|
@Test |
|
|
|
public void testSendAlarmToCloud() throws Exception { |
|
|
|
@ -23,6 +23,7 @@ import org.thingsboard.server.common.data.asset.Asset; |
|
|
|
import org.thingsboard.server.common.data.edge.Edge; |
|
|
|
import org.thingsboard.server.common.data.id.CustomerId; |
|
|
|
import org.thingsboard.server.common.data.id.EntityId; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.gen.edge.v1.AssetProfileUpdateMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.AssetUpdateMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.UpdateMsgType; |
|
|
|
@ -32,7 +33,8 @@ import java.util.UUID; |
|
|
|
|
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
abstract public class BaseAssetEdgeTest extends AbstractEdgeTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class AssetEdgeTest extends AbstractEdgeTest { |
|
|
|
|
|
|
|
@Test |
|
|
|
public void testAssets() throws Exception { |
|
|
|
@ -21,6 +21,7 @@ import org.junit.Assert; |
|
|
|
import org.junit.Test; |
|
|
|
import org.thingsboard.server.common.data.asset.AssetProfile; |
|
|
|
import org.thingsboard.server.common.data.id.RuleChainId; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.gen.edge.v1.AssetProfileUpdateMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.UpdateMsgType; |
|
|
|
|
|
|
|
@ -28,7 +29,8 @@ import java.nio.charset.StandardCharsets; |
|
|
|
|
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
abstract public class BaseAssetProfileEdgeTest extends AbstractEdgeTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class AssetProfileEdgeTest extends AbstractEdgeTest { |
|
|
|
|
|
|
|
@Test |
|
|
|
public void testAssetProfiles() throws Exception { |
|
|
|
@ -20,6 +20,7 @@ import org.junit.Assert; |
|
|
|
import org.junit.Test; |
|
|
|
import org.thingsboard.server.common.data.Customer; |
|
|
|
import org.thingsboard.server.common.data.edge.Edge; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.gen.edge.v1.CustomerUpdateMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.EdgeConfiguration; |
|
|
|
import org.thingsboard.server.gen.edge.v1.UpdateMsgType; |
|
|
|
@ -28,7 +29,8 @@ import java.util.Optional; |
|
|
|
|
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
abstract public class BaseCustomerEdgeTest extends AbstractEdgeTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class CustomerEdgeTest extends AbstractEdgeTest { |
|
|
|
|
|
|
|
@Test |
|
|
|
public void testCreateUpdateDeleteCustomer() throws Exception { |
|
|
|
@ -24,6 +24,7 @@ import org.thingsboard.server.common.data.Customer; |
|
|
|
import org.thingsboard.server.common.data.Dashboard; |
|
|
|
import org.thingsboard.server.common.data.ShortCustomerInfo; |
|
|
|
import org.thingsboard.server.common.data.edge.Edge; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.gen.edge.v1.DashboardUpdateMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.UpdateMsgType; |
|
|
|
|
|
|
|
@ -31,7 +32,8 @@ import java.util.Set; |
|
|
|
|
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
abstract public class BaseDashboardEdgeTest extends AbstractEdgeTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class DashboardEdgeTest extends AbstractEdgeTest { |
|
|
|
|
|
|
|
@Test |
|
|
|
public void testDashboards() throws Exception { |
|
|
|
@ -52,6 +52,7 @@ import org.thingsboard.server.common.data.security.DeviceCredentialsType; |
|
|
|
import org.thingsboard.server.common.data.tenant.profile.DefaultTenantProfileConfiguration; |
|
|
|
import org.thingsboard.server.common.msg.session.FeatureType; |
|
|
|
import org.thingsboard.server.common.transport.adaptor.JsonConverter; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.gen.edge.v1.AttributesRequestMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.DeviceCredentialsRequestMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.DeviceCredentialsUpdateMsg; |
|
|
|
@ -79,7 +80,8 @@ import static org.springframework.test.web.servlet.result.MockMvcResultMatchers. |
|
|
|
@TestPropertySource(properties = { |
|
|
|
"transport.mqtt.enabled=true" |
|
|
|
}) |
|
|
|
abstract public class BaseDeviceEdgeTest extends AbstractEdgeTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class DeviceEdgeTest extends AbstractEdgeTest { |
|
|
|
|
|
|
|
@Test |
|
|
|
public void testDevices() throws Exception { |
|
|
|
@ -43,6 +43,7 @@ import org.thingsboard.server.common.data.ota.OtaPackageType; |
|
|
|
import org.thingsboard.server.common.data.transport.snmp.SnmpMapping; |
|
|
|
import org.thingsboard.server.common.data.transport.snmp.config.SnmpCommunicationConfig; |
|
|
|
import org.thingsboard.server.common.data.transport.snmp.config.impl.TelemetryQueryingSnmpCommunicationConfig; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.gen.edge.v1.DeviceProfileUpdateMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.UpdateMsgType; |
|
|
|
import org.thingsboard.server.transport.AbstractTransportIntegrationTest; |
|
|
|
@ -54,7 +55,8 @@ import java.util.Optional; |
|
|
|
|
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
abstract public class BaseDeviceProfileEdgeTest extends AbstractEdgeTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class DeviceProfileEdgeTest extends AbstractEdgeTest { |
|
|
|
|
|
|
|
@Test |
|
|
|
public void testDeviceProfiles() throws Exception { |
|
|
|
@ -21,6 +21,7 @@ import org.thingsboard.server.common.data.Customer; |
|
|
|
import org.thingsboard.server.common.data.edge.Edge; |
|
|
|
import org.thingsboard.server.common.data.id.CustomerId; |
|
|
|
import org.thingsboard.server.common.data.id.EntityId; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.gen.edge.v1.CustomerUpdateMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.EdgeConfiguration; |
|
|
|
import org.thingsboard.server.gen.edge.v1.UpdateMsgType; |
|
|
|
@ -28,7 +29,8 @@ import org.thingsboard.server.gen.edge.v1.UpdateMsgType; |
|
|
|
import java.util.Optional; |
|
|
|
import java.util.UUID; |
|
|
|
|
|
|
|
abstract public class BaseEdgeTest extends AbstractEdgeTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class EdgeTest extends AbstractEdgeTest { |
|
|
|
|
|
|
|
@Test |
|
|
|
public void testEdge_assignToCustomer_unassignFromCustomer() throws Exception { |
|
|
|
@ -25,6 +25,7 @@ import org.thingsboard.server.common.data.EntityView; |
|
|
|
import org.thingsboard.server.common.data.edge.Edge; |
|
|
|
import org.thingsboard.server.common.data.id.CustomerId; |
|
|
|
import org.thingsboard.server.common.data.id.EntityId; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.gen.edge.v1.EntityViewUpdateMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.EntityViewsRequestMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.UpdateMsgType; |
|
|
|
@ -34,7 +35,8 @@ import java.util.UUID; |
|
|
|
|
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
abstract public class BaseEntityViewEdgeTest extends AbstractEdgeTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class EntityViewEdgeTest extends AbstractEdgeTest { |
|
|
|
|
|
|
|
@Test |
|
|
|
public void testEntityViews() throws Exception { |
|
|
|
@ -27,6 +27,7 @@ import org.thingsboard.server.common.data.OtaPackageInfo; |
|
|
|
import org.thingsboard.server.common.data.SaveOtaPackageInfoRequest; |
|
|
|
import org.thingsboard.server.common.data.ota.ChecksumAlgorithm; |
|
|
|
import org.thingsboard.server.common.data.ota.OtaPackageType; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.gen.edge.v1.OtaPackageUpdateMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.UpdateMsgType; |
|
|
|
|
|
|
|
@ -35,7 +36,8 @@ import java.nio.ByteBuffer; |
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
import static org.thingsboard.server.common.data.ota.OtaPackageType.FIRMWARE; |
|
|
|
|
|
|
|
abstract public class BaseOtaPackageEdgeTest extends AbstractEdgeTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class OtaPackageEdgeTest extends AbstractEdgeTest { |
|
|
|
|
|
|
|
@Test |
|
|
|
public void testOtaPackages_usesUrl() throws Exception { |
|
|
|
@ -24,12 +24,14 @@ import org.thingsboard.server.common.data.queue.Queue; |
|
|
|
import org.thingsboard.server.common.data.queue.SubmitStrategy; |
|
|
|
import org.thingsboard.server.common.data.queue.SubmitStrategyType; |
|
|
|
import org.thingsboard.server.common.msg.queue.ServiceType; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.gen.edge.v1.QueueUpdateMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.UpdateMsgType; |
|
|
|
|
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
abstract public class BaseQueueEdgeTest extends AbstractEdgeTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class QueueEdgeTest extends AbstractEdgeTest { |
|
|
|
|
|
|
|
@Test |
|
|
|
public void testQueues() throws Exception { |
|
|
|
@ -24,6 +24,7 @@ import org.thingsboard.server.common.data.id.EntityId; |
|
|
|
import org.thingsboard.server.common.data.id.EntityIdFactory; |
|
|
|
import org.thingsboard.server.common.data.relation.EntityRelation; |
|
|
|
import org.thingsboard.server.common.data.relation.RelationTypeGroup; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.gen.edge.v1.RelationRequestMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.RelationUpdateMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.UpdateMsgType; |
|
|
|
@ -33,7 +34,8 @@ import java.util.UUID; |
|
|
|
|
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
abstract public class BaseRelationEdgeTest extends AbstractEdgeTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class RelationEdgeTest extends AbstractEdgeTest { |
|
|
|
|
|
|
|
|
|
|
|
@Test |
|
|
|
@ -24,6 +24,7 @@ import org.thingsboard.server.common.data.rule.RuleChain; |
|
|
|
import org.thingsboard.server.common.data.rule.RuleChainMetaData; |
|
|
|
import org.thingsboard.server.common.data.rule.RuleChainType; |
|
|
|
import org.thingsboard.server.common.data.rule.RuleNode; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.gen.edge.v1.RuleChainMetadataRequestMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.RuleChainMetadataUpdateMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.RuleChainUpdateMsg; |
|
|
|
@ -37,7 +38,8 @@ import java.util.UUID; |
|
|
|
|
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
abstract public class BaseRuleChainEdgeTest extends AbstractEdgeTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class RuleChainEdgeTest extends AbstractEdgeTest { |
|
|
|
|
|
|
|
@Test |
|
|
|
public void testRuleChains() throws Exception { |
|
|
|
@ -30,6 +30,7 @@ import org.thingsboard.server.common.data.edge.EdgeEvent; |
|
|
|
import org.thingsboard.server.common.data.edge.EdgeEventActionType; |
|
|
|
import org.thingsboard.server.common.data.edge.EdgeEventType; |
|
|
|
import org.thingsboard.server.common.data.id.EntityId; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.gen.edge.v1.AttributeDeleteMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.DeviceUpdateMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.EntityDataProto; |
|
|
|
@ -39,7 +40,8 @@ import org.thingsboard.server.gen.transport.TransportProtos; |
|
|
|
import java.util.List; |
|
|
|
import java.util.concurrent.TimeUnit; |
|
|
|
|
|
|
|
abstract public class BaseTelemetryEdgeTest extends AbstractEdgeTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class TelemetryEdgeTest extends AbstractEdgeTest { |
|
|
|
|
|
|
|
@Test |
|
|
|
public void testTimeseriesWithFailures() throws Exception { |
|
|
|
@ -24,6 +24,7 @@ import org.thingsboard.server.common.data.Customer; |
|
|
|
import org.thingsboard.server.common.data.User; |
|
|
|
import org.thingsboard.server.common.data.edge.Edge; |
|
|
|
import org.thingsboard.server.common.data.security.Authority; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.gen.edge.v1.UpdateMsgType; |
|
|
|
import org.thingsboard.server.gen.edge.v1.UplinkMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.UserCredentialsRequestMsg; |
|
|
|
@ -35,7 +36,8 @@ import java.util.Optional; |
|
|
|
|
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
abstract public class BaseUserEdgeTest extends AbstractEdgeTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class UserEdgeTest extends AbstractEdgeTest { |
|
|
|
|
|
|
|
@Autowired |
|
|
|
private BCryptPasswordEncoder passwordEncoder; |
|
|
|
@ -22,13 +22,15 @@ import org.junit.Test; |
|
|
|
import org.thingsboard.common.util.JacksonUtil; |
|
|
|
import org.thingsboard.server.common.data.widget.WidgetType; |
|
|
|
import org.thingsboard.server.common.data.widget.WidgetsBundle; |
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.gen.edge.v1.UpdateMsgType; |
|
|
|
import org.thingsboard.server.gen.edge.v1.WidgetTypeUpdateMsg; |
|
|
|
import org.thingsboard.server.gen.edge.v1.WidgetsBundleUpdateMsg; |
|
|
|
|
|
|
|
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; |
|
|
|
|
|
|
|
abstract public class BaseWidgetEdgeTest extends AbstractEdgeTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class WidgetEdgeTest extends AbstractEdgeTest { |
|
|
|
|
|
|
|
@Test |
|
|
|
public void testWidgetsBundleAndWidgetType() throws Exception { |
|
|
|
@ -1,24 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.edge.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.edge.BaseAlarmEdgeTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class AlarmEdgeSqlTest extends BaseAlarmEdgeTest { |
|
|
|
|
|
|
|
} |
|
|
|
@ -1,24 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.edge.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.edge.BaseAssetEdgeTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class AssetEdgeSqlTest extends BaseAssetEdgeTest { |
|
|
|
|
|
|
|
} |
|
|
|
@ -1,24 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.edge.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.edge.BaseAssetProfileEdgeTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class AssetProfileEdgeSqlTest extends BaseAssetProfileEdgeTest { |
|
|
|
|
|
|
|
} |
|
|
|
@ -1,24 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.edge.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.edge.BaseCustomerEdgeTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class CustomerEdgeSqlTest extends BaseCustomerEdgeTest { |
|
|
|
|
|
|
|
} |
|
|
|
@ -1,24 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.edge.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.edge.BaseDashboardEdgeTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class DashboardEdgeSqlTest extends BaseDashboardEdgeTest { |
|
|
|
|
|
|
|
} |
|
|
|
@ -1,24 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.edge.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.edge.BaseDeviceEdgeTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class DeviceEdgeSqlTest extends BaseDeviceEdgeTest { |
|
|
|
|
|
|
|
} |
|
|
|
@ -1,24 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.edge.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.edge.BaseDeviceProfileEdgeTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class DeviceProfileEdgeSqlTest extends BaseDeviceProfileEdgeTest { |
|
|
|
|
|
|
|
} |
|
|
|
@ -1,24 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.edge.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.edge.BaseEdgeTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class EdgeSqlTest extends BaseEdgeTest { |
|
|
|
|
|
|
|
} |
|
|
|
@ -1,24 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.edge.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.edge.BaseEntityViewEdgeTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class EntityViewEdgeSqlTest extends BaseEntityViewEdgeTest { |
|
|
|
|
|
|
|
} |
|
|
|
@ -1,24 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.edge.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.edge.BaseOtaPackageEdgeTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class OtaPackageEdgeSqlTest extends BaseOtaPackageEdgeTest { |
|
|
|
|
|
|
|
} |
|
|
|
@ -1,24 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.edge.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.edge.BaseQueueEdgeTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class QueueEdgeSqlTest extends BaseQueueEdgeTest { |
|
|
|
|
|
|
|
} |
|
|
|
@ -1,24 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.edge.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.edge.BaseRelationEdgeTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class RelationEdgeSqlTest extends BaseRelationEdgeTest { |
|
|
|
|
|
|
|
} |
|
|
|
@ -1,24 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.edge.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.edge.BaseRuleChainEdgeTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class RuleChainEdgeSqlTest extends BaseRuleChainEdgeTest { |
|
|
|
|
|
|
|
} |
|
|
|
@ -1,24 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.edge.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.edge.BaseTelemetryEdgeTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class TelemetryEdgeSqlTest extends BaseTelemetryEdgeTest { |
|
|
|
|
|
|
|
} |
|
|
|
@ -1,24 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.edge.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.edge.BaseUserEdgeTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class UserEdgeSqlTest extends BaseUserEdgeTest { |
|
|
|
|
|
|
|
} |
|
|
|
@ -1,24 +0,0 @@ |
|
|
|
/** |
|
|
|
* Copyright © 2016-2023 The Thingsboard Authors |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
package org.thingsboard.server.edge.sql; |
|
|
|
|
|
|
|
import org.thingsboard.server.dao.service.DaoSqlTest; |
|
|
|
import org.thingsboard.server.edge.BaseWidgetEdgeTest; |
|
|
|
|
|
|
|
@DaoSqlTest |
|
|
|
public class WidgetEdgeSqlTest extends BaseWidgetEdgeTest { |
|
|
|
|
|
|
|
} |
|
|
|
@ -31,7 +31,8 @@ import org.thingsboard.server.dao.settings.AdminSettingsService; |
|
|
|
import static org.assertj.core.api.Assertions.assertThatThrownBy; |
|
|
|
import static org.junit.jupiter.api.Assertions.assertDoesNotThrow; |
|
|
|
|
|
|
|
public abstract class BaseAdminSettingsServiceTest extends AbstractServiceTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class AdminSettingsServiceTest extends AbstractServiceTest { |
|
|
|
|
|
|
|
@Autowired |
|
|
|
AdminSettingsService adminSettingsService; |
|
|
|
@ -43,7 +43,8 @@ import java.util.concurrent.ExecutionException; |
|
|
|
|
|
|
|
import static org.thingsboard.server.common.data.alarm.AlarmCommentType.OTHER; |
|
|
|
|
|
|
|
public abstract class BaseAlarmCommentServiceTest extends AbstractServiceTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class AlarmCommentServiceTest extends AbstractServiceTest { |
|
|
|
|
|
|
|
@Autowired |
|
|
|
AlarmService alarmService; |
|
|
|
@ -62,7 +62,8 @@ import java.util.Collections; |
|
|
|
import java.util.List; |
|
|
|
import java.util.concurrent.ExecutionException; |
|
|
|
|
|
|
|
public abstract class BaseAlarmServiceTest extends AbstractServiceTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class AlarmServiceTest extends AbstractServiceTest { |
|
|
|
|
|
|
|
@Autowired |
|
|
|
AlarmService alarmService; |
|
|
|
@ -23,7 +23,8 @@ import org.thingsboard.server.common.data.ApiUsageStateValue; |
|
|
|
import org.thingsboard.server.dao.usagerecord.ApiUsageStateService; |
|
|
|
|
|
|
|
|
|
|
|
public abstract class BaseApiUsageStateServiceTest extends AbstractServiceTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class ApiUsageStateServiceTest extends AbstractServiceTest { |
|
|
|
|
|
|
|
@Autowired |
|
|
|
ApiUsageStateService apiUsageStateService; |
|
|
|
@ -40,7 +40,8 @@ import java.util.concurrent.ExecutionException; |
|
|
|
import java.util.concurrent.Executors; |
|
|
|
import java.util.stream.Collectors; |
|
|
|
|
|
|
|
public abstract class BaseAssetProfileServiceTest extends AbstractServiceTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class AssetProfileServiceTest extends AbstractServiceTest { |
|
|
|
|
|
|
|
private IdComparator<AssetProfile> idComparator = new IdComparator<>(); |
|
|
|
private IdComparator<AssetProfileInfo> assetProfileInfoIdComparator = new IdComparator<>(); |
|
|
|
@ -40,7 +40,8 @@ import java.util.List; |
|
|
|
|
|
|
|
import static org.thingsboard.server.dao.model.ModelConstants.NULL_UUID; |
|
|
|
|
|
|
|
public abstract class BaseAssetServiceTest extends AbstractServiceTest { |
|
|
|
@DaoSqlTest |
|
|
|
public class AssetServiceTest extends AbstractServiceTest { |
|
|
|
|
|
|
|
@Autowired |
|
|
|
AssetService assetService; |