Showing
5 changed files
with
17 additions
and
12 deletions
@@ -197,9 +197,8 @@ | @@ -197,9 +197,8 @@ | ||
197 | <artifactId>springfox-swagger2</artifactId> | 197 | <artifactId>springfox-swagger2</artifactId> |
198 | </dependency> | 198 | </dependency> |
199 | <dependency> | 199 | <dependency> |
200 | - <groupId>org.thingsboard.server</groupId> | 200 | + <groupId>org.thingsboard</groupId> |
201 | <artifactId>tools</artifactId> | 201 | <artifactId>tools</artifactId> |
202 | - <version>0.0.1-SNAPSHOT</version> | ||
203 | <scope>test</scope> | 202 | <scope>test</scope> |
204 | </dependency> | 203 | </dependency> |
205 | <dependency> | 204 | <dependency> |
application/src/test/java/org/thingsboard/server/mqtt/AbstractFeatureIntegrationTest.java
renamed from
application/src/test/java/org/thingsboard/server/rpc/AbstractRpcIntegrationTest.java
@@ -13,7 +13,7 @@ | @@ -13,7 +13,7 @@ | ||
13 | * See the License for the specific language governing permissions and | 13 | * See the License for the specific language governing permissions and |
14 | * limitations under the License. | 14 | * limitations under the License. |
15 | */ | 15 | */ |
16 | -package org.thingsboard.server.rpc; | 16 | +package org.thingsboard.server.mqtt; |
17 | 17 | ||
18 | import org.junit.runner.RunWith; | 18 | import org.junit.runner.RunWith; |
19 | import org.springframework.beans.factory.annotation.Autowired; | 19 | import org.springframework.beans.factory.annotation.Autowired; |
@@ -31,7 +31,7 @@ import org.springframework.test.context.TestPropertySource; | @@ -31,7 +31,7 @@ import org.springframework.test.context.TestPropertySource; | ||
31 | import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; | 31 | import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; |
32 | import org.springframework.test.context.web.WebAppConfiguration; | 32 | import org.springframework.test.context.web.WebAppConfiguration; |
33 | import org.springframework.web.context.WebApplicationContext; | 33 | import org.springframework.web.context.WebApplicationContext; |
34 | -import org.thingsboard.server.rpc.mqtt.MqttRpcIntergrationTest; | 34 | +import org.thingsboard.server.mqtt.telemetry.MqttTelemetryIntergrationTest; |
35 | 35 | ||
36 | import java.util.Arrays; | 36 | import java.util.Arrays; |
37 | 37 | ||
@@ -42,7 +42,7 @@ import static org.junit.Assert.assertNotNull; | @@ -42,7 +42,7 @@ import static org.junit.Assert.assertNotNull; | ||
42 | */ | 42 | */ |
43 | @ActiveProfiles("default") | 43 | @ActiveProfiles("default") |
44 | @RunWith(SpringJUnit4ClassRunner.class) | 44 | @RunWith(SpringJUnit4ClassRunner.class) |
45 | -@ContextConfiguration(classes=MqttRpcIntergrationTest.class, loader=SpringApplicationContextLoader.class) | 45 | +@ContextConfiguration(classes= MqttTelemetryIntergrationTest.class, loader=SpringApplicationContextLoader.class) |
46 | @TestPropertySource("classpath:cassandra-test.properties") | 46 | @TestPropertySource("classpath:cassandra-test.properties") |
47 | @DirtiesContext(classMode = DirtiesContext.ClassMode.AFTER_CLASS) | 47 | @DirtiesContext(classMode = DirtiesContext.ClassMode.AFTER_CLASS) |
48 | @Configuration | 48 | @Configuration |
@@ -50,7 +50,7 @@ import static org.junit.Assert.assertNotNull; | @@ -50,7 +50,7 @@ import static org.junit.Assert.assertNotNull; | ||
50 | @ComponentScan({"org.thingsboard.server"}) | 50 | @ComponentScan({"org.thingsboard.server"}) |
51 | @WebAppConfiguration | 51 | @WebAppConfiguration |
52 | @IntegrationTest("server.port:8080") | 52 | @IntegrationTest("server.port:8080") |
53 | -public class AbstractRpcIntegrationTest { | 53 | +public class AbstractFeatureIntegrationTest { |
54 | 54 | ||
55 | @SuppressWarnings("rawtypes") | 55 | @SuppressWarnings("rawtypes") |
56 | private HttpMessageConverter mappingJackson2HttpMessageConverter; | 56 | private HttpMessageConverter mappingJackson2HttpMessageConverter; |
application/src/test/java/org/thingsboard/server/mqtt/MqttSuite.java
renamed from
application/src/test/java/org/thingsboard/server/rpc/mqtt/MqttRpcSuite.java
@@ -13,7 +13,7 @@ | @@ -13,7 +13,7 @@ | ||
13 | * See the License for the specific language governing permissions and | 13 | * See the License for the specific language governing permissions and |
14 | * limitations under the License. | 14 | * limitations under the License. |
15 | */ | 15 | */ |
16 | -package org.thingsboard.server.rpc.mqtt; | 16 | +package org.thingsboard.server.mqtt; |
17 | 17 | ||
18 | import org.cassandraunit.dataset.cql.ClassPathCQLDataSet; | 18 | import org.cassandraunit.dataset.cql.ClassPathCQLDataSet; |
19 | import org.junit.ClassRule; | 19 | import org.junit.ClassRule; |
@@ -27,8 +27,8 @@ import java.util.Arrays; | @@ -27,8 +27,8 @@ import java.util.Arrays; | ||
27 | * @author Valerii Sosliuk | 27 | * @author Valerii Sosliuk |
28 | */ | 28 | */ |
29 | @RunWith(ClasspathSuite.class) | 29 | @RunWith(ClasspathSuite.class) |
30 | -@ClasspathSuite.ClassnameFilters({"org.thingsboard.server.rpc.mqtt.*Test"}) | ||
31 | -public class MqttRpcSuite { | 30 | +@ClasspathSuite.ClassnameFilters({"org.thingsboard.server.mqtt.*.*Test"}) |
31 | +public class MqttSuite { | ||
32 | 32 | ||
33 | @ClassRule | 33 | @ClassRule |
34 | public static CustomCassandraCQLUnit cassandraUnit = | 34 | public static CustomCassandraCQLUnit cassandraUnit = |
application/src/test/java/org/thingsboard/server/mqtt/telemetry/MqttTelemetryIntergrationTest.java
renamed from
application/src/test/java/org/thingsboard/server/rpc/mqtt/MqttRpcIntergrationTest.java
@@ -13,7 +13,7 @@ | @@ -13,7 +13,7 @@ | ||
13 | * See the License for the specific language governing permissions and | 13 | * See the License for the specific language governing permissions and |
14 | * limitations under the License. | 14 | * limitations under the License. |
15 | */ | 15 | */ |
16 | -package org.thingsboard.server.rpc.mqtt; | 16 | +package org.thingsboard.server.mqtt.telemetry; |
17 | 17 | ||
18 | import lombok.extern.slf4j.Slf4j; | 18 | import lombok.extern.slf4j.Slf4j; |
19 | import org.eclipse.paho.client.mqttv3.MqttAsyncClient; | 19 | import org.eclipse.paho.client.mqttv3.MqttAsyncClient; |
@@ -25,7 +25,7 @@ import org.springframework.web.util.UriComponentsBuilder; | @@ -25,7 +25,7 @@ import org.springframework.web.util.UriComponentsBuilder; | ||
25 | import org.thingsboard.client.tools.RestClient; | 25 | import org.thingsboard.client.tools.RestClient; |
26 | import org.thingsboard.server.common.data.Device; | 26 | import org.thingsboard.server.common.data.Device; |
27 | import org.thingsboard.server.common.data.security.DeviceCredentials; | 27 | import org.thingsboard.server.common.data.security.DeviceCredentials; |
28 | -import org.thingsboard.server.rpc.AbstractRpcIntegrationTest; | 28 | +import org.thingsboard.server.mqtt.AbstractFeatureIntegrationTest; |
29 | 29 | ||
30 | import java.net.URI; | 30 | import java.net.URI; |
31 | import java.util.Arrays; | 31 | import java.util.Arrays; |
@@ -39,7 +39,7 @@ import static org.junit.Assert.assertNotNull; | @@ -39,7 +39,7 @@ import static org.junit.Assert.assertNotNull; | ||
39 | * @author Valerii Sosliuk | 39 | * @author Valerii Sosliuk |
40 | */ | 40 | */ |
41 | @Slf4j | 41 | @Slf4j |
42 | -public class MqttRpcIntergrationTest extends AbstractRpcIntegrationTest { | 42 | +public class MqttTelemetryIntergrationTest extends AbstractFeatureIntegrationTest { |
43 | 43 | ||
44 | private static final String MQTT_URL = "tcp://localhost:1883"; | 44 | private static final String MQTT_URL = "tcp://localhost:1883"; |
45 | private static final String BASE_URL = "http://localhost:8080"; | 45 | private static final String BASE_URL = "http://localhost:8080"; |
@@ -366,6 +366,12 @@ | @@ -366,6 +366,12 @@ | ||
366 | </dependency> | 366 | </dependency> |
367 | <dependency> | 367 | <dependency> |
368 | <groupId>org.thingsboard</groupId> | 368 | <groupId>org.thingsboard</groupId> |
369 | + <artifactId>tools</artifactId> | ||
370 | + <version>${project.version}</version> | ||
371 | + <scope>test</scope> | ||
372 | + </dependency> | ||
373 | + <dependency> | ||
374 | + <groupId>org.thingsboard</groupId> | ||
369 | <artifactId>dao</artifactId> | 375 | <artifactId>dao</artifactId> |
370 | <version>${project.version}</version> | 376 | <version>${project.version}</version> |
371 | <type>test-jar</type> | 377 | <type>test-jar</type> |