Commit b330ff4b77d822ce9b8512282314692b76714c60

Authored by YunaiV
1 parent edc460a2

fix(iot):禁用 iot 不通过的单测,避免影响编译

yudao-module-iot/yudao-module-iot-gateway/src/test/java/cn/iocoder/yudao/module/iot/gateway/protocol/coap/IotGatewayDeviceCoapProtocolIntegrationTest.java
1 package cn.iocoder.yudao.module.iot.gateway.protocol.coap; 1 package cn.iocoder.yudao.module.iot.gateway.protocol.coap;
2 2
  3 +import cn.hutool.core.collection.ListUtil;
3 import cn.hutool.core.map.MapUtil; 4 import cn.hutool.core.map.MapUtil;
4 import cn.hutool.core.util.IdUtil; 5 import cn.hutool.core.util.IdUtil;
5 import cn.iocoder.yudao.framework.common.util.json.JsonUtils; 6 import cn.iocoder.yudao.framework.common.util.json.JsonUtils;
@@ -27,7 +28,6 @@ import org.junit.jupiter.api.Disabled; @@ -27,7 +28,6 @@ import org.junit.jupiter.api.Disabled;
27 import org.junit.jupiter.api.Test; 28 import org.junit.jupiter.api.Test;
28 29
29 import java.util.Collections; 30 import java.util.Collections;
30 -import java.util.List;  
31 import java.util.Map; 31 import java.util.Map;
32 32
33 /** 33 /**
@@ -344,7 +344,7 @@ public class IotGatewayDeviceCoapProtocolIntegrationTest { @@ -344,7 +344,7 @@ public class IotGatewayDeviceCoapProtocolIntegrationTest {
344 IotDevicePropertyPackPostReqDTO params = new IotDevicePropertyPackPostReqDTO(); 344 IotDevicePropertyPackPostReqDTO params = new IotDevicePropertyPackPostReqDTO();
345 params.setProperties(gatewayProperties); 345 params.setProperties(gatewayProperties);
346 params.setEvents(gatewayEvents); 346 params.setEvents(gatewayEvents);
347 - params.setSubDevices(List.of(subDeviceData)); 347 + params.setSubDevices(ListUtil.of(subDeviceData));
348 String payload = JsonUtils.toJsonString(MapUtil.builder() 348 String payload = JsonUtils.toJsonString(MapUtil.builder()
349 .put("id", IdUtil.fastSimpleUUID()) 349 .put("id", IdUtil.fastSimpleUUID())
350 .put("method", IotDeviceMessageMethodEnum.PROPERTY_PACK_POST.getMethod()) 350 .put("method", IotDeviceMessageMethodEnum.PROPERTY_PACK_POST.getMethod())
yudao-module-iot/yudao-module-iot-gateway/src/test/java/cn/iocoder/yudao/module/iot/gateway/protocol/http/IotGatewayDeviceHttpProtocolIntegrationTest.java
1 package cn.iocoder.yudao.module.iot.gateway.protocol.http; 1 package cn.iocoder.yudao.module.iot.gateway.protocol.http;
2 2
  3 +import cn.hutool.core.collection.ListUtil;
3 import cn.hutool.core.map.MapUtil; 4 import cn.hutool.core.map.MapUtil;
4 import cn.hutool.core.util.IdUtil; 5 import cn.hutool.core.util.IdUtil;
5 import cn.hutool.http.HttpResponse; 6 import cn.hutool.http.HttpResponse;
@@ -288,7 +289,7 @@ public class IotGatewayDeviceHttpProtocolIntegrationTest { @@ -288,7 +289,7 @@ public class IotGatewayDeviceHttpProtocolIntegrationTest {
288 IotDevicePropertyPackPostReqDTO params = new IotDevicePropertyPackPostReqDTO(); 289 IotDevicePropertyPackPostReqDTO params = new IotDevicePropertyPackPostReqDTO();
289 params.setProperties(gatewayProperties); 290 params.setProperties(gatewayProperties);
290 params.setEvents(gatewayEvents); 291 params.setEvents(gatewayEvents);
291 - params.setSubDevices(List.of(subDeviceData)); 292 + params.setSubDevices(ListUtil.of(subDeviceData));
292 String payload = JsonUtils.toJsonString(MapUtil.builder() 293 String payload = JsonUtils.toJsonString(MapUtil.builder()
293 .put("id", IdUtil.fastSimpleUUID()) 294 .put("id", IdUtil.fastSimpleUUID())
294 .put("method", IotDeviceMessageMethodEnum.PROPERTY_PACK_POST.getMethod()) 295 .put("method", IotDeviceMessageMethodEnum.PROPERTY_PACK_POST.getMethod())
yudao-module-iot/yudao-module-iot-gateway/src/test/java/cn/iocoder/yudao/module/iot/gateway/protocol/mqtt/IotGatewayDeviceMqttProtocolIntegrationTest.java
1 package cn.iocoder.yudao.module.iot.gateway.protocol.mqtt; 1 package cn.iocoder.yudao.module.iot.gateway.protocol.mqtt;
2 2
  3 +import cn.hutool.core.collection.ListUtil;
3 import cn.hutool.core.map.MapUtil; 4 import cn.hutool.core.map.MapUtil;
4 import cn.hutool.core.util.IdUtil; 5 import cn.hutool.core.util.IdUtil;
5 import cn.iocoder.yudao.module.iot.core.biz.dto.IotDeviceAuthReqDTO; 6 import cn.iocoder.yudao.module.iot.core.biz.dto.IotDeviceAuthReqDTO;
@@ -350,7 +351,7 @@ public class IotGatewayDeviceMqttProtocolIntegrationTest { @@ -350,7 +351,7 @@ public class IotGatewayDeviceMqttProtocolIntegrationTest {
350 IotDevicePropertyPackPostReqDTO params = new IotDevicePropertyPackPostReqDTO(); 351 IotDevicePropertyPackPostReqDTO params = new IotDevicePropertyPackPostReqDTO();
351 params.setProperties(gatewayProperties); 352 params.setProperties(gatewayProperties);
352 params.setEvents(gatewayEvents); 353 params.setEvents(gatewayEvents);
353 - params.setSubDevices(List.of(subDeviceData)); 354 + params.setSubDevices(ListUtil.of(subDeviceData));
354 IotDeviceMessage request = IotDeviceMessage.of( 355 IotDeviceMessage request = IotDeviceMessage.of(
355 IdUtil.fastSimpleUUID(), 356 IdUtil.fastSimpleUUID(),
356 IotDeviceMessageMethodEnum.PROPERTY_PACK_POST.getMethod(), 357 IotDeviceMessageMethodEnum.PROPERTY_PACK_POST.getMethod(),
yudao-module-iot/yudao-module-iot-gateway/src/test/java/cn/iocoder/yudao/module/iot/gateway/protocol/tcp/IotGatewayDeviceTcpProtocolIntegrationTest.java
1 package cn.iocoder.yudao.module.iot.gateway.protocol.tcp; 1 package cn.iocoder.yudao.module.iot.gateway.protocol.tcp;
2 2
  3 +import cn.hutool.core.collection.ListUtil;
3 import cn.hutool.core.map.MapUtil; 4 import cn.hutool.core.map.MapUtil;
4 import cn.hutool.core.util.IdUtil; 5 import cn.hutool.core.util.IdUtil;
5 import cn.iocoder.yudao.module.iot.core.biz.dto.IotDeviceAuthReqDTO; 6 import cn.iocoder.yudao.module.iot.core.biz.dto.IotDeviceAuthReqDTO;
@@ -316,7 +317,7 @@ public class IotGatewayDeviceTcpProtocolIntegrationTest { @@ -316,7 +317,7 @@ public class IotGatewayDeviceTcpProtocolIntegrationTest {
316 IotDevicePropertyPackPostReqDTO params = new IotDevicePropertyPackPostReqDTO(); 317 IotDevicePropertyPackPostReqDTO params = new IotDevicePropertyPackPostReqDTO();
317 params.setProperties(gatewayProperties); 318 params.setProperties(gatewayProperties);
318 params.setEvents(gatewayEvents); 319 params.setEvents(gatewayEvents);
319 - params.setSubDevices(List.of(subDeviceData)); 320 + params.setSubDevices(ListUtil.of(subDeviceData));
320 IotDeviceMessage request = IotDeviceMessage.of( 321 IotDeviceMessage request = IotDeviceMessage.of(
321 IdUtil.fastSimpleUUID(), 322 IdUtil.fastSimpleUUID(),
322 IotDeviceMessageMethodEnum.PROPERTY_PACK_POST.getMethod(), 323 IotDeviceMessageMethodEnum.PROPERTY_PACK_POST.getMethod(),
yudao-module-iot/yudao-module-iot-gateway/src/test/java/cn/iocoder/yudao/module/iot/gateway/protocol/udp/IotGatewayDeviceUdpProtocolIntegrationTest.java
1 package cn.iocoder.yudao.module.iot.gateway.protocol.udp; 1 package cn.iocoder.yudao.module.iot.gateway.protocol.udp;
2 2
  3 +import cn.hutool.core.collection.ListUtil;
3 import cn.hutool.core.map.MapUtil; 4 import cn.hutool.core.map.MapUtil;
4 import cn.hutool.core.util.IdUtil; 5 import cn.hutool.core.util.IdUtil;
5 import cn.iocoder.yudao.module.iot.core.biz.dto.IotDeviceAuthReqDTO; 6 import cn.iocoder.yudao.module.iot.core.biz.dto.IotDeviceAuthReqDTO;
@@ -305,7 +306,7 @@ public class IotGatewayDeviceUdpProtocolIntegrationTest { @@ -305,7 +306,7 @@ public class IotGatewayDeviceUdpProtocolIntegrationTest {
305 IotDevicePropertyPackPostReqDTO params = new IotDevicePropertyPackPostReqDTO(); 306 IotDevicePropertyPackPostReqDTO params = new IotDevicePropertyPackPostReqDTO();
306 params.setProperties(gatewayProperties); 307 params.setProperties(gatewayProperties);
307 params.setEvents(gatewayEvents); 308 params.setEvents(gatewayEvents);
308 - params.setSubDevices(List.of(subDeviceData)); 309 + params.setSubDevices(ListUtil.of(subDeviceData));
309 IotDeviceMessage request = IotDeviceMessage.of( 310 IotDeviceMessage request = IotDeviceMessage.of(
310 IdUtil.fastSimpleUUID(), 311 IdUtil.fastSimpleUUID(),
311 IotDeviceMessageMethodEnum.PROPERTY_PACK_POST.getMethod(), 312 IotDeviceMessageMethodEnum.PROPERTY_PACK_POST.getMethod(),
yudao-module-iot/yudao-module-iot-gateway/src/test/java/cn/iocoder/yudao/module/iot/gateway/protocol/websocket/IotGatewayDeviceWebSocketProtocolIntegrationTest.java
1 package cn.iocoder.yudao.module.iot.gateway.protocol.websocket; 1 package cn.iocoder.yudao.module.iot.gateway.protocol.websocket;
2 2
  3 +import cn.hutool.core.collection.ListUtil;
3 import cn.hutool.core.map.MapUtil; 4 import cn.hutool.core.map.MapUtil;
4 import cn.hutool.core.util.IdUtil; 5 import cn.hutool.core.util.IdUtil;
5 import cn.hutool.core.util.StrUtil; 6 import cn.hutool.core.util.StrUtil;
@@ -26,7 +27,6 @@ import org.junit.jupiter.api.Disabled; @@ -26,7 +27,6 @@ import org.junit.jupiter.api.Disabled;
26 import org.junit.jupiter.api.Test; 27 import org.junit.jupiter.api.Test;
27 28
28 import java.util.Collections; 29 import java.util.Collections;
29 -import java.util.List;  
30 import java.util.Map; 30 import java.util.Map;
31 import java.util.concurrent.CountDownLatch; 31 import java.util.concurrent.CountDownLatch;
32 import java.util.concurrent.TimeUnit; 32 import java.util.concurrent.TimeUnit;
@@ -352,7 +352,7 @@ public class IotGatewayDeviceWebSocketProtocolIntegrationTest { @@ -352,7 +352,7 @@ public class IotGatewayDeviceWebSocketProtocolIntegrationTest {
352 IotDevicePropertyPackPostReqDTO params = new IotDevicePropertyPackPostReqDTO(); 352 IotDevicePropertyPackPostReqDTO params = new IotDevicePropertyPackPostReqDTO();
353 params.setProperties(gatewayProperties); 353 params.setProperties(gatewayProperties);
354 params.setEvents(gatewayEvents); 354 params.setEvents(gatewayEvents);
355 - params.setSubDevices(List.of(subDeviceData)); 355 + params.setSubDevices(ListUtil.of(subDeviceData));
356 IotDeviceMessage request = IotDeviceMessage.of( 356 IotDeviceMessage request = IotDeviceMessage.of(
357 IdUtil.fastSimpleUUID(), 357 IdUtil.fastSimpleUUID(),
358 IotDeviceMessageMethodEnum.PROPERTY_PACK_POST.getMethod(), 358 IotDeviceMessageMethodEnum.PROPERTY_PACK_POST.getMethod(),