diff options
Diffstat (limited to 'tests/system-traffic.at')
-rw-r--r-- | tests/system-traffic.at | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/tests/system-traffic.at b/tests/system-traffic.at index 9df8b62ad..34342d661 100644 --- a/tests/system-traffic.at +++ b/tests/system-traffic.at @@ -10,9 +10,9 @@ ADD_VETH(p0, at_ns0, br0, "10.1.1.1/24") ADD_VETH(p1, at_ns1, br0, "10.1.1.2/24") AT_CAPTURE_FILE([ping.output]) -AT_CHECK([ip netns exec at_ns0 bash -c "ping -q -c 3 -i 0.3 -w 2 10.1.1.2 > ping.output"]) -AT_CHECK([ip netns exec at_ns0 bash -c "ping -s 1600 -q -c 3 -i 0.3 -w 2 10.1.1.2 >> ping.output"]) -AT_CHECK([ip netns exec at_ns0 bash -c "ping -s 3200 -q -c 3 -i 0.3 -w 2 10.1.1.2 >> ping.output"]) +NS_CHECK_EXEC([at_ns0], [ping -q -c 3 -i 0.3 -w 2 10.1.1.2 > ping.output]) +NS_CHECK_EXEC([at_ns0], [ping -s 1600 -q -c 3 -i 0.3 -w 2 10.1.1.2 >> ping.output]) +NS_CHECK_EXEC([at_ns0], [ping -s 3200 -q -c 3 -i 0.3 -w 2 10.1.1.2 >> ping.output]) AT_CHECK([cat ping.output | grep "transmitted" | sed 's/time.*ms$/time 0ms/'], [0], [dnl 3 packets transmitted, 3 received, 0% packet loss, time 0ms @@ -36,9 +36,9 @@ ADD_VLAN(p0, at_ns0, 100, "10.2.2.1/24") ADD_VLAN(p1, at_ns1, 100, "10.2.2.2/24") AT_CAPTURE_FILE([ping.output]) -AT_CHECK([ip netns exec at_ns0 bash -c "ping -q -c 3 -i 0.3 -w 2 10.2.2.2 > ping.output"]) -AT_CHECK([ip netns exec at_ns0 bash -c "ping -s 1600 -q -c 3 -i 0.3 -w 2 10.2.2.2 >> ping.output"]) -AT_CHECK([ip netns exec at_ns0 bash -c "ping -s 3200 -q -c 3 -i 0.3 -w 2 10.2.2.2 >> ping.output"]) +NS_CHECK_EXEC([at_ns0], [ping -q -c 3 -i 0.3 -w 2 10.2.2.2 > ping.output]) +NS_CHECK_EXEC([at_ns0], [ping -s 1600 -q -c 3 -i 0.3 -w 2 10.2.2.2 >> ping.output]) +NS_CHECK_EXEC([at_ns0], [ping -s 3200 -q -c 3 -i 0.3 -w 2 10.2.2.2 >> ping.output]) AT_CHECK([cat ping.output | grep "transmitted" | sed 's/time.*ms$/time 0ms/'], [0], [dnl 3 packets transmitted, 3 received, 0% packet loss, time 0ms @@ -63,9 +63,9 @@ dnl "connect: Cannot assign requested address" sleep 2; AT_CAPTURE_FILE([ping.output]) -AT_CHECK([ip netns exec at_ns0 bash -c "ping6 -q -c 3 -i 0.3 -w 2 fc00::2 > ping.output"]) -AT_CHECK([ip netns exec at_ns0 bash -c "ping6 -s 1600 -q -c 3 -i 0.3 -w 2 fc00::2 >> ping.output"]) -AT_CHECK([ip netns exec at_ns0 bash -c "ping6 -s 3200 -q -c 3 -i 0.3 -w 2 fc00::2 >> ping.output"]) +NS_CHECK_EXEC([at_ns0], [ping6 -q -c 3 -i 0.3 -w 2 fc00::2 > ping.output]) +NS_CHECK_EXEC([at_ns0], [ping6 -s 1600 -q -c 3 -i 0.3 -w 2 fc00::2 >> ping.output]) +NS_CHECK_EXEC([at_ns0], [ping6 -s 3200 -q -c 3 -i 0.3 -w 2 fc00::2 >> ping.output]) AT_CHECK([cat ping.output | grep "transmitted" | sed 's/time.*ms$/time 0ms/'], [0], [dnl 3 packets transmitted, 3 received, 0% packet loss, time 0ms @@ -93,9 +93,9 @@ dnl "connect: Cannot assign requested address" sleep 2; AT_CAPTURE_FILE([ping.output]) -AT_CHECK([ip netns exec at_ns0 bash -c "ping6 -q -c 3 -i 0.3 -w 2 fc00:1::2 > ping.output"]) -AT_CHECK([ip netns exec at_ns0 bash -c "ping6 -s 1600 -q -c 3 -i 0.3 -w 2 fc00:1::2 >> ping.output"]) -AT_CHECK([ip netns exec at_ns0 bash -c "ping6 -s 3200 -q -c 3 -i 0.3 -w 2 fc00:1::2 >> ping.output"]) +NS_CHECK_EXEC([at_ns0], [ping6 -q -c 3 -i 0.3 -w 2 fc00:1::2 > ping.output]) +NS_CHECK_EXEC([at_ns0], [ping6 -s 1600 -q -c 3 -i 0.3 -w 2 fc00:1::2 >> ping.output]) +NS_CHECK_EXEC([at_ns0], [ping6 -s 3200 -q -c 3 -i 0.3 -w 2 fc00:1::2 >> ping.output]) AT_CHECK([cat ping.output | grep "transmitted" | sed 's/time.*ms$/time 0ms/'], [0], [dnl 3 packets transmitted, 3 received, 0% packet loss, time 0ms |