From 563f38909f0053ffae02dc2badc185570ee16183 Mon Sep 17 00:00:00 2001 From: yunhanw-google Date: Mon, 4 Oct 2021 15:48:09 -0700 Subject: [PATCH] move all cirque test to ipv6 only (#10200) --- src/app/tests/integration/chip_im_initiator.cpp | 2 +- src/app/tests/integration/chip_im_responder.cpp | 9 ++------- src/messaging/tests/echo/echo_requester.cpp | 4 ++-- src/messaging/tests/echo/echo_responder.cpp | 9 ++------- src/test_driver/linux-cirque/EchoOverTcpTest.py | 4 +++- src/test_driver/linux-cirque/EchoTest.py | 4 +++- src/test_driver/linux-cirque/InteractionModelTest.py | 4 +++- src/test_driver/linux-cirque/MobileDeviceTest.py | 4 +++- third_party/cirque/repo | 2 +- 9 files changed, 20 insertions(+), 22 deletions(-) diff --git a/src/app/tests/integration/chip_im_initiator.cpp b/src/app/tests/integration/chip_im_initiator.cpp index a11e8cc178688d..a4d67460153fe3 100644 --- a/src/app/tests/integration/chip_im_initiator.cpp +++ b/src/app/tests/integration/chip_im_initiator.cpp @@ -697,7 +697,7 @@ int main(int argc, char * argv[]) InitializeChip(); err = gTransportManager.Init(chip::Transport::UdpListenParameters(&chip::DeviceLayer::InetLayer) - .SetAddressType(gDestAddr.Type()) + .SetAddressType(chip::Inet::kIPAddressType_IPv6) .SetListenPort(IM_CLIENT_PORT)); SuccessOrExit(err); diff --git a/src/app/tests/integration/chip_im_responder.cpp b/src/app/tests/integration/chip_im_responder.cpp index afbc3f03cd5fd2..32bca99538bce4 100644 --- a/src/app/tests/integration/chip_im_responder.cpp +++ b/src/app/tests/integration/chip_im_responder.cpp @@ -206,13 +206,8 @@ int main(int argc, char * argv[]) InitializeChip(); - err = gTransportManager.Init(chip::Transport::UdpListenParameters(&chip::DeviceLayer::InetLayer) -#if INET_CONFIG_ENABLE_IPV4 - .SetAddressType(chip::Inet::kIPAddressType_IPv4) -#else - .SetAddressType(chip::Inet::kIPAddressType_IPv6) -#endif - ); + err = gTransportManager.Init( + chip::Transport::UdpListenParameters(&chip::DeviceLayer::InetLayer).SetAddressType(chip::Inet::kIPAddressType_IPv6)); SuccessOrExit(err); err = gSessionManager.Init(&chip::DeviceLayer::SystemLayer(), &gTransportManager, &gMessageCounterManager); diff --git a/src/messaging/tests/echo/echo_requester.cpp b/src/messaging/tests/echo/echo_requester.cpp index 12af4bf86aec71..a62bdf53fc0021 100644 --- a/src/messaging/tests/echo/echo_requester.cpp +++ b/src/messaging/tests/echo/echo_requester.cpp @@ -228,7 +228,7 @@ int main(int argc, char * argv[]) if (gUseTCP) { err = gTCPManager.Init(chip::Transport::TcpListenParameters(&chip::DeviceLayer::InetLayer) - .SetAddressType(gDestAddr.Type()) + .SetAddressType(chip::Inet::kIPAddressType_IPv6) .SetListenPort(ECHO_CLIENT_PORT)); SuccessOrExit(err); @@ -238,7 +238,7 @@ int main(int argc, char * argv[]) else { err = gUDPManager.Init(chip::Transport::UdpListenParameters(&chip::DeviceLayer::InetLayer) - .SetAddressType(gDestAddr.Type()) + .SetAddressType(chip::Inet::kIPAddressType_IPv6) .SetListenPort(ECHO_CLIENT_PORT)); SuccessOrExit(err); diff --git a/src/messaging/tests/echo/echo_responder.cpp b/src/messaging/tests/echo/echo_responder.cpp index a3a058ded27527..8a9ade91791728 100644 --- a/src/messaging/tests/echo/echo_responder.cpp +++ b/src/messaging/tests/echo/echo_responder.cpp @@ -97,13 +97,8 @@ int main(int argc, char * argv[]) } else { - err = gUDPManager.Init(chip::Transport::UdpListenParameters(&chip::DeviceLayer::InetLayer) -#if INET_CONFIG_ENABLE_IPV4 - .SetAddressType(chip::Inet::kIPAddressType_IPv4) -#else - .SetAddressType(chip::Inet::kIPAddressType_IPv6) -#endif - ); + err = gUDPManager.Init( + chip::Transport::UdpListenParameters(&chip::DeviceLayer::InetLayer).SetAddressType(chip::Inet::kIPAddressType_IPv6)); SuccessOrExit(err); err = gSessionManager.Init(&chip::DeviceLayer::SystemLayer(), &gUDPManager, &gMessageCounterManager); diff --git a/src/test_driver/linux-cirque/EchoOverTcpTest.py b/src/test_driver/linux-cirque/EchoOverTcpTest.py index 53c6948782bc23..853e2cb9749bd0 100755 --- a/src/test_driver/linux-cirque/EchoOverTcpTest.py +++ b/src/test_driver/linux-cirque/EchoOverTcpTest.py @@ -40,6 +40,7 @@ 'base_image': 'connectedhomeip/chip-cirque-device-base', 'capability': ['Thread', 'Interactive', 'TrafficControl', 'Mount'], 'rcp_mode': True, + 'docker_network': 'Ipv6', 'traffic_control': {'latencyMs': 100}, "mount_pairs": [[CHIP_REPO, CHIP_REPO]], }, @@ -48,6 +49,7 @@ 'base_image': 'connectedhomeip/chip-cirque-device-base', 'capability': ['Thread', 'Interactive', 'TrafficControl', 'Mount'], 'rcp_mode': True, + 'docker_network': 'Ipv6', 'traffic_control': {'latencyMs': 100}, "mount_pairs": [[CHIP_REPO, CHIP_REPO]], } @@ -71,7 +73,7 @@ def test_routine(self): self.run_data_model_test() def run_data_model_test(self): - resp_ips = [device['description']['ipv4_addr'] for device in self.non_ap_devices + resp_ips = [device['description']['ipv6_addr'] for device in self.non_ap_devices if device['type'] == 'CHIP-Echo-Responder'] resp_ids = [device['id'] for device in self.non_ap_devices if device['type'] == 'CHIP-Echo-Responder'] diff --git a/src/test_driver/linux-cirque/EchoTest.py b/src/test_driver/linux-cirque/EchoTest.py index e4f648ffe537db..91464046f3f9b8 100755 --- a/src/test_driver/linux-cirque/EchoTest.py +++ b/src/test_driver/linux-cirque/EchoTest.py @@ -40,6 +40,7 @@ 'base_image': 'connectedhomeip/chip-cirque-device-base', 'capability': ['Thread', 'Interactive', 'TrafficControl', 'Mount'], 'rcp_mode': True, + 'docker_network': 'Ipv6', 'traffic_control': {'latencyMs': 100}, "mount_pairs": [[CHIP_REPO, CHIP_REPO]], }, @@ -48,6 +49,7 @@ 'base_image': 'connectedhomeip/chip-cirque-device-base', 'capability': ['Thread', 'Interactive', 'TrafficControl', 'Mount'], 'rcp_mode': True, + 'docker_network': 'Ipv6', 'traffic_control': {'latencyMs': 100}, "mount_pairs": [[CHIP_REPO, CHIP_REPO]], } @@ -71,7 +73,7 @@ def test_routine(self): self.run_data_model_test() def run_data_model_test(self): - resp_ips = [device['description']['ipv4_addr'] for device in self.non_ap_devices + resp_ips = [device['description']['ipv6_addr'] for device in self.non_ap_devices if device['type'] == 'CHIP-Echo-Responder'] resp_ids = [device['id'] for device in self.non_ap_devices if device['type'] == 'CHIP-Echo-Responder'] diff --git a/src/test_driver/linux-cirque/InteractionModelTest.py b/src/test_driver/linux-cirque/InteractionModelTest.py index 50c826006714a5..fb1b8d275444e4 100755 --- a/src/test_driver/linux-cirque/InteractionModelTest.py +++ b/src/test_driver/linux-cirque/InteractionModelTest.py @@ -40,6 +40,7 @@ 'base_image': 'connectedhomeip/chip-cirque-device-base', 'capability': ['Thread', 'Interactive', 'TrafficControl', 'Mount'], 'rcp_mode': True, + 'docker_network': 'Ipv6', 'traffic_control': {'latencyMs': 100}, "mount_pairs": [[CHIP_REPO, CHIP_REPO]], }, @@ -48,6 +49,7 @@ 'base_image': 'connectedhomeip/chip-cirque-device-base', 'capability': ['Thread', 'Interactive', 'TrafficControl', 'Mount'], 'rcp_mode': True, + 'docker_network': 'Ipv6', 'traffic_control': {'latencyMs': 100}, "mount_pairs": [[CHIP_REPO, CHIP_REPO]], } @@ -71,7 +73,7 @@ def test_routine(self): self.run_data_model_test() def run_data_model_test(self): - resp_ips = [device['description']['ipv4_addr'] for device in self.non_ap_devices + resp_ips = [device['description']['ipv6_addr'] for device in self.non_ap_devices if device['type'] == 'CHIP-IM-Responder'] resp_ids = [device['id'] for device in self.non_ap_devices if device['type'] == 'CHIP-IM-Responder'] diff --git a/src/test_driver/linux-cirque/MobileDeviceTest.py b/src/test_driver/linux-cirque/MobileDeviceTest.py index 7420cd2aa545a6..1a3f485388ef04 100755 --- a/src/test_driver/linux-cirque/MobileDeviceTest.py +++ b/src/test_driver/linux-cirque/MobileDeviceTest.py @@ -45,6 +45,7 @@ 'base_image': 'connectedhomeip/chip-cirque-device-base', 'capability': ['Interactive', 'TrafficControl', 'Mount'], 'rcp_mode': True, + 'docker_network': 'Ipv6', 'traffic_control': {'latencyMs': 100}, "mount_pairs": [[CHIP_REPO, CHIP_REPO]], }, @@ -53,6 +54,7 @@ 'base_image': 'connectedhomeip/chip-cirque-device-base', 'capability': ['Thread', 'Interactive', 'TrafficControl', 'Mount'], 'rcp_mode': True, + 'docker_network': 'Ipv6', 'traffic_control': {'latencyMs': 100}, "mount_pairs": [[CHIP_REPO, CHIP_REPO]], } @@ -71,7 +73,7 @@ def test_routine(self): self.run_controller_test() def run_controller_test(self): - ethernet_ip = [device['description']['ipv4_addr'] for device in self.non_ap_devices + ethernet_ip = [device['description']['ipv6_addr'] for device in self.non_ap_devices if device['type'] == 'CHIPEndDevice'][0] server_ids = [device['id'] for device in self.non_ap_devices if device['type'] == 'CHIPEndDevice'] diff --git a/third_party/cirque/repo b/third_party/cirque/repo index 32fa9289a8846b..a1229f065a2f94 160000 --- a/third_party/cirque/repo +++ b/third_party/cirque/repo @@ -1 +1 @@ -Subproject commit 32fa9289a8846b6c653f60e36648d95fc315bb85 +Subproject commit a1229f065a2f94e64072a678415ae49f90c2d058