aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rwxr-xr-xtest/scripts/core_pinning.sh328
-rw-r--r--test/test_abf.py8
-rw-r--r--test/test_flowprobe.py2
-rw-r--r--test/test_gso.py40
-rw-r--r--test/test_gtpu.py4
-rw-r--r--test/test_ip6.py2
-rw-r--r--test/test_ip6_nd_mirror_proxy.py2
-rw-r--r--test/test_ipip.py6
-rw-r--r--test/test_l3xc.py2
-rw-r--r--test/test_linux_cp.py2
-rw-r--r--test/test_map.py2
-rw-r--r--test/test_map_br.py4
-rw-r--r--test/test_mpls.py2
-rw-r--r--test/test_nat44_ed_output.py2
-rw-r--r--test/test_neighbor.py1
-rw-r--r--test/test_pcap.py2
-rw-r--r--test/test_reassembly.py34
-rw-r--r--test/test_srv6_mobile.py8
-rw-r--r--test/test_trace_filter.py2
-rw-r--r--test/test_vxlan.py1
20 files changed, 60 insertions, 394 deletions
diff --git a/test/scripts/core_pinning.sh b/test/scripts/core_pinning.sh
deleted file mode 100755
index 941d53871e5..00000000000
--- a/test/scripts/core_pinning.sh
+++ /dev/null
@@ -1,328 +0,0 @@
-#!/bin/bash
-#
-# core_pinning_auto.sh -- script to test vpp (debug-build) core-pinning
-# -- in bare-metal, containers (docker, lxc)
-#
-DOCKER_CONTAINER_NAME="vpp_core_pinning"
-VPP_SOCK_PATH=/run/vpp
-CONTAINER_CPU_RANGE="4-7"
-TEST_SUCCESS=0
-TEST_FAIL=0
-if [ ! $WS_ROOT ]
-then
- if [ ! -d "../../../vpp" ]; then
- echo "VPP workspace path invalid"
- echo "Please execute script from vpp/test/scripts folder.."
- exit 1
- fi
- WS_ROOT="$(dirname $(readlink -e "../../../vpp"))/$(basename "../../../vpp")"
-fi
-# Get available CPU count on host machine
-host_cpulist=$(cat /sys/devices/system/cpu/online)
-startcpu="${host_cpulist%-*}"
-endcpu="${host_cpulist#*\-}"
-cpucount="$(($endcpu - $startcpu + 1))"
-if [ $cpucount -lt 8 ]
-then
- echo "Current host machine has $cpucount CPUs"
- echo "A minimum of 8 CPUs is required to run testcases, exiting.."
- exit 1
-fi
-# Check that container 'vpp_core_pinning' does not already exist
-count=$(docker ps -a | grep -c "$DOCKER_CONTAINER_NAME")
-if [ $count -ne 0 ]
-then
- echo "Error: docker container $DOCKER_CONTAINER_NAME already exists"
- echo "Remove it using 'docker stop/docker rm', then re-run test"
- exit 1
-fi
-# Check that there is no vpp instance currently running on the machine
-count=$(pgrep vpp | wc -l)
-if [ $count -ne 0 ]
-then
- echo "Error: a vpp instance is currently running on this machine"
- echo "Please stop the running instance, then re-run test"
- exit 1
-fi
-mkdir -p $VPP_SOCK_PATH
-
-# Function to parse main core
-parse_maincore () {
- main_core_args=$1
- main_core_parsed=$main_core_args
- if [ $main_core_args = "auto" ];
- then
- main_core_parsed="0"
- if [ -n "$SKIP_CORE" ]
- then
- main_core_parsed=$(($main_core_parsed + $SKIP_CORE))
- fi
- if [ -n "$CONTAINER_RESTRAIN_CPUSET" ]
- then
- main_core_parsed=(${container_cpus[ $main_core_parsed ]})
- fi
- fi
- echo $main_core_parsed
-}
-
-# Function to parse n workers range to an array
-# e.g. "4" is parsed to ('0','1','2','3')
-parse_workers_n () {
- workers_n_args=$1
- workers_n_parsed=()
- main_core_increment="0"
- skip_core_increment="0"
- if [ -n "$SKIP_CORE" ]
- then
- skip_core_increment=$(($SKIP_CORE))
- fi
-
- for ((i=0;i<$workers_n_args;i++)); do
-
- if [ -n "$CONTAINER_RESTRAIN_CPUSET" ]
- then
- if [ $(( ${container_cpus[ $(($i + $skip_core_increment)) ]})) -eq $(("$parsed_main_core")) ]
- then
- main_core_increment=$(($main_core_increment + 1))
- fi
- workers_n_parsed+=" ${container_cpus[ $(($i + $main_core_increment + $skip_core_increment)) ]}"
- else
- if [ $(( $skip_core_increment + $i)) -eq $(("$parsed_main_core")) ]
- then
- main_core_increment=$(($main_core_increment + 1))
- fi
- workers_n_parsed+=" $(($i + $main_core_increment + $skip_core_increment))"
- fi
- done
- echo $workers_n_parsed
-}
-
-# Function to parse corelist range to an array
-# e.g. "0,3-5,7" is parsed to ('0','3','4','5','7')
-parse_corelist () {
- corelist_args=$1
- corelist_args=$(echo $corelist_args | grep -Po '[0-9]+-[0-9]+|[0-9]+')
- corelist_parsed=()
- for corelist_elt in ${corelist_args[@]};do
- if [ $(echo $corelist_elt | grep -Po '[0-9]+-[0-9]+') ]
- then
- startcpu="${corelist_elt%-*}"
- endcpu="${corelist_elt#*\-}"
- cpucount="$(($endcpu - $startcpu))"
- for ((i=0;i<=$cpucount;i++)); do
- corelist_parsed+=" $(($i+$startcpu))"
- done
- elif [ $(echo $corelist_elt | grep -Po '[0-9]+') ]
- then
- corelist_parsed+=" ${corelist_elt}"
- fi
- done
- echo $corelist_parsed
-}
-# Test VPP core pinning configuration
-test_pinning_conf () {
- VPP_CPU_EXTRA_OPTIONS=""
- if [ -n "$CORELIST_WORKERS" ];
- then
- VPP_CPU_EXTRA_OPTIONS=" corelist-workers ${CORELIST_WORKERS}"
- fi
- if [ -n "$WORKERS_AUTO" ];
- then
- VPP_CPU_EXTRA_OPTIONS=" workers ${WORKERS_AUTO}"
- fi
- if [ -n "$SKIP_CORE" ];
- then
- VPP_CPU_EXTRA_OPTIONS="${VPP_CPU_EXTRA_OPTIONS} skip-cores ${SKIP_CORE}"
- fi
- echo "TEST - conf 'cpu {main-core ${MAIN_CORE} ${VPP_CPU_EXTRA_OPTIONS}}'"
- if [ -z "$CONTAINER_RESTRAIN_CPUSET" ];
- then
- VPP_CONTAINER_CPUSET=""
- echo "(Running vpp in container with full host cpuset $host_cpulist)"
- else
- VPP_CONTAINER_CPUSET="--cpuset-cpus $CONTAINER_CPU_RANGE"
- echo "(Running vpp in container with limited cpuset $CONTAINER_CPU_RANGE)"
- fi
- (docker run -d ${VPP_CONTAINER_CPUSET} --name="$DOCKER_CONTAINER_NAME" \
- -e LD_LIBRARY_PATH="/vpp/build-root/build-vpp_debug-native/vpp/lib/x86_64-linux-gnu/" -v $VPP_SOCK_PATH:$VPP_SOCK_PATH \
- -v $WS_ROOT:/vpp ubuntu:22.04 sh -c "/vpp/build-root/build-vpp_debug-native/vpp/bin/vpp unix {interactive \
- nodaemon cli-listen $VPP_SOCK_PATH/cli.sock} cpu {main-core ${MAIN_CORE} ${VPP_CPU_EXTRA_OPTIONS} } plugins \
- { plugin dpdk_plugin.so {disable } }" > /dev/null )
- sleep 3 # wait for VPP to initialize socket
- # Change access permissions on vpp cli socket
- # docker exec -it "$DOCKER_CONTAINER_NAME" /bin/bash -c "chmod 777 $VPP_SOCK_PATH/cli.sock" > /dev/null
- # check if vppctl can connect to vpp container instance
- $WS_ROOT/build-root/build-vpp_debug-native/vpp/bin/vppctl -s $VPP_SOCK_PATH/cli.sock show threads 1> /dev/null
- # get CPUs vpp instance in container is running on
- taskset_vpp_cpus=($( taskset --all-tasks -pc $(pgrep vpp) | grep -e ".$" -o))
- rc=$?
- # parse list of user requested CPUs for vpp
- requested_cpus=()
- parsed_main_core=$(parse_maincore ${MAIN_CORE})
- requested_cpus+=($parsed_main_core)
- if [ -n "$CORELIST_WORKERS" ];
- then
- requested_cpus+=($(parse_corelist ${CORELIST_WORKERS}))
- fi
- if [ -n "$WORKERS_AUTO" ];
- then
- requested_cpus+=($(parse_workers_n ${WORKERS_AUTO}))
- fi
-
- # parse list of expected CPUs used by vpp
- expected_cpu_mapping=()
- expected_cpu_mapping=("${requested_cpus[@]}")
- echo "CPUs requested by user: [${requested_cpus[@]}]"
- echo "--------------------"
- echo "Expected CPU Mapping: [${expected_cpu_mapping[@]}]"
- echo "VPP pinning (taskset): [${taskset_vpp_cpus[@]}]"
- #check if expected CPU mapping matches CPUs vpp instance in container is running on
- failure_cond=""
- for index in ${!taskset_vpp_cpus[@]}; do
- if [ ${taskset_vpp_cpus[$index]} -ne ${expected_cpu_mapping[ $index ]} ]
- then
- failure_cond="t"
- fi
- done
- if [ $rc -eq 0 ] && [ -z "$failure_cond" ]
- then
- echo "Test Successful"
- TEST_SUCCESS=$(($TEST_SUCCESS+1))
- else
- echo "Test Failed"
- TEST_FAIL=$(($TEST_FAIL+1))
- fi
- echo "=============================================="
- echo " "
- # Stop & destroy container instance
- docker stop $DOCKER_CONTAINER_NAME &> /dev/null
- docker rm -f $DOCKER_CONTAINER_NAME &> /dev/null
-}
-test_invalid_conf () {
- if [ -n "$CORELIST_WORKERS" ];
- then
- VPP_CPU_EXTRA_OPTIONS=" corelist-workers ${CORELIST_WORKERS}"
- fi
- if [ -n "$WORKERS_AUTO" ];
- then
- VPP_CPU_EXTRA_OPTIONS=" workers ${WORKERS_AUTO}"
- fi
- if [ -n "$SKIP_CORE" ];
- then
- VPP_CPU_EXTRA_OPTIONS="${VPP_CPU_EXTRA_OPTIONS} skip-cores ${SKIP_CORE}"
- fi
- echo "TEST - conf 'cpu {main-core ${MAIN_CORE} ${VPP_CPU_EXTRA_OPTIONS}}'"
- if [ -z "$CONTAINER_RESTRAIN_CPUSET" ];
- then
- VPP_CONTAINER_CPUSET=""
- echo "(Running vpp in container with full host cpuset $host_cpulist)"
- else
- VPP_CONTAINER_CPUSET="--cpuset-cpus $CONTAINER_CPU_RANGE"
- echo "(Running vpp in container with limited cpuset $CONTAINER_CPU_RANGE)"
- fi
- (docker run -d --cpuset-cpus $CONTAINER_CPU_RANGE --name="$DOCKER_CONTAINER_NAME" \
- -e LD_LIBRARY_PATH="/vpp/build-root/build-vpp_debug-native/vpp/lib/x86_64-linux-gnu/" -v $VPP_SOCK_PATH:$VPP_SOCK_PATH \
- -v $WS_ROOT:/vpp ubuntu:22.04 sh -c "/vpp/build-root/build-vpp_debug-native/vpp/bin/vpp unix {interactive \
- nodaemon cli-listen $VPP_SOCK_PATH/cli.sock} cpu {main-core ${MAIN_CORE} ${VPP_CPU_EXTRA_OPTIONS}} plugins \
- { plugin dpdk_plugin.so {disable } }" > /dev/null)
- sleep 3 # wait for vpp to initialize socket
- # check if vpp launched with invalid configuration
- taskset --all-tasks -pc $(pgrep vpp) &> /dev/null
- rc=$?
- if [ $rc -eq 1 ]
- then
- echo " "
- echo "OK... VPP did not launch with invalid configuration"
- TEST_SUCCESS=$(($TEST_SUCCESS+1))
- else
- echo " "
- echo "Failure... VPP launched with wrong configuration"
- TEST_FAIL=$(($TEST_FAIL+1))
- fi
- echo "=============================================="
- echo " "
- # Stop & destroy container instance
- docker stop $DOCKER_CONTAINER_NAME &> /dev/null
- docker rm -f $DOCKER_CONTAINER_NAME &> /dev/null
-}
-run_tests () {
- container_cpus=($(parse_corelist ${CONTAINER_CPU_RANGE}))
- echo "TESTING VALID CORE PINNING CONFIGURATIONS"
- echo " "
- WORKERS_AUTO=""
- SKIP_CORE=""
- CONTAINER_RESTRAIN_CPUSET=""
- CORELIST_WORKERS="1-3"
- MAIN_CORE="0"
- test_pinning_conf
- WORKERS_AUTO=""
- SKIP_CORE=""
- CONTAINER_RESTRAIN_CPUSET=""
- CORELIST_WORKERS="0,2-3"
- MAIN_CORE="1"
- test_pinning_conf
- WORKERS_AUTO=""
- SKIP_CORE=""
- CONTAINER_RESTRAIN_CPUSET=""
- CORELIST_WORKERS="0-2"
- MAIN_CORE="3"
- test_pinning_conf
- WORKERS_AUTO="2"
- SKIP_CORE=""
- CONTAINER_RESTRAIN_CPUSET=""
- CORELIST_WORKERS=""
- MAIN_CORE="auto"
- test_pinning_conf
- WORKERS_AUTO="3"
- SKIP_CORE=""
- CONTAINER_RESTRAIN_CPUSET="t"
- CORELIST_WORKERS=""
- MAIN_CORE="auto"
- test_pinning_conf
- WORKERS_AUTO="2"
- SKIP_CORE="1"
- CONTAINER_RESTRAIN_CPUSET="t"
- CORELIST_WORKERS=""
- MAIN_CORE="auto"
- test_pinning_conf
- WORKERS_AUTO="2"
- SKIP_CORE=""
- CONTAINER_RESTRAIN_CPUSET="t"
- CORELIST_WORKERS=""
- MAIN_CORE="5"
- test_pinning_conf
- echo "TESTING NON-VALID CORE PINNING CONFIGURATIONS"
- echo " "
- WORKERS_AUTO=""
- SKIP_CORE=""
- CONTAINER_RESTRAIN_CPUSET="t"
- CORELIST_WORKERS="1-3"
- MAIN_CORE="0"
- test_invalid_conf
- WORKERS_AUTO="3"
- SKIP_CORE="1"
- CONTAINER_RESTRAIN_CPUSET="t"
- CORELIST_WORKERS=""
- MAIN_CORE="auto"
- test_invalid_conf
- WORKERS_AUTO="5"
- SKIP_CORE=""
- CONTAINER_RESTRAIN_CPUSET="t"
- CORELIST_WORKERS=""
- MAIN_CORE="auto"
- test_invalid_conf
- WORKERS_AUTO=""
- SKIP_CORE="4"
- CONTAINER_RESTRAIN_CPUSET="t"
- CORELIST_WORKERS=""
- MAIN_CORE="auto"
- test_invalid_conf
- echo " "
- echo "========================"
- echo "RESULTS:"
- echo "SUCCESS: $TEST_SUCCESS"
- echo "FAILURE: $TEST_FAIL"
- echo "========================"
- echo " "
-}
-run_tests \ No newline at end of file
diff --git a/test/test_abf.py b/test/test_abf.py
index 3baec9f9e9b..ec329a0ec9b 100644
--- a/test/test_abf.py
+++ b/test/test_abf.py
@@ -391,7 +391,7 @@ class TestAbf(VppTestCase):
# a packet matching the deny rule
#
p_deny = (
- Ether(src=self.pg0.remote_mac, dst=self.pg3.remote_mac)
+ Ether(src=self.pg0.remote_mac, dst=self.pg0.local_mac)
/ IP(src=self.pg0.remote_ip4, dst=self.pg3.remote_ip4)
/ UDP(sport=1234, dport=1234)
/ Raw(b"\xa5" * 100)
@@ -402,7 +402,7 @@ class TestAbf(VppTestCase):
# a packet matching the permit rule
#
p_permit = (
- Ether(src=self.pg0.remote_mac, dst=self.pg2.remote_mac)
+ Ether(src=self.pg0.remote_mac, dst=self.pg0.local_mac)
/ IP(src=self.pg0.remote_ip4, dst=self.pg2.remote_ip4)
/ UDP(sport=1234, dport=1234)
/ Raw(b"\xa5" * 100)
@@ -454,7 +454,7 @@ class TestAbf(VppTestCase):
# a packet matching the deny rule
#
p_deny = (
- Ether(src=self.pg0.remote_mac, dst=self.pg3.remote_mac)
+ Ether(src=self.pg0.remote_mac, dst=self.pg0.local_mac)
/ IPv6(src=self.pg0.remote_ip6, dst=self.pg3.remote_ip6)
/ UDP(sport=1234, dport=1234)
/ Raw(b"\xa5" * 100)
@@ -465,7 +465,7 @@ class TestAbf(VppTestCase):
# a packet matching the permit rule
#
p_permit = (
- Ether(src=self.pg0.remote_mac, dst=self.pg2.remote_mac)
+ Ether(src=self.pg0.remote_mac, dst=self.pg0.local_mac)
/ IPv6(src=self.pg0.remote_ip6, dst=self.pg2.remote_ip6)
/ UDP(sport=1234, dport=1234)
/ Raw(b"\xa5" * 100)
diff --git a/test/test_flowprobe.py b/test/test_flowprobe.py
index ac0433abc00..8e3fecfd7b4 100644
--- a/test/test_flowprobe.py
+++ b/test/test_flowprobe.py
@@ -559,7 +559,7 @@ class Flowprobe(MethodHolder):
# make a tcp packet
self.pkts = [
(
- Ether(src=self.pg3.remote_mac, dst=self.pg4.local_mac)
+ Ether(src=self.pg3.remote_mac, dst=self.pg3.local_mac)
/ IP(src=self.pg3.remote_ip4, dst=self.pg4.remote_ip4)
/ TCP(sport=1234, dport=4321)
/ Raw(b"\xa5" * 50)
diff --git a/test/test_gso.py b/test/test_gso.py
index 78c5c734660..3d9ce5fb4ee 100644
--- a/test/test_gso.py
+++ b/test/test_gso.py
@@ -405,7 +405,7 @@ class TestGSO(VppTestCase):
# IPv4/IPv4 - VXLAN
#
p45 = (
- Ether(src=self.pg2.remote_mac, dst="02:fe:60:1e:a2:79")
+ Ether(src=self.pg2.remote_mac, dst=self.pg2.local_mac)
/ IP(src=self.pg2.remote_ip4, dst="172.16.3.3", flags="DF")
/ TCP(sport=1234, dport=1234)
/ Raw(b"\xa5" * 65200)
@@ -419,12 +419,12 @@ class TestGSO(VppTestCase):
self.assertEqual(rx[IP].src, self.pg0.local_ip4)
self.assertEqual(rx[IP].dst, self.pg0.remote_ip4)
self.assert_ip_checksum_valid(rx)
- self.assert_udp_checksum_valid(rx, ignore_zero_checksum=False)
+ self.assert_udp_checksum_valid(rx, ignore_zero_checksum=True)
self.assertEqual(rx[VXLAN].vni, 10)
inner = rx[VXLAN].payload
self.assertEqual(rx[IP].len - 20 - 8 - 8, len(inner))
self.assertEqual(inner[Ether].src, self.pg2.remote_mac)
- self.assertEqual(inner[Ether].dst, "02:fe:60:1e:a2:79")
+ self.assertEqual(inner[Ether].dst, self.pg2.local_mac)
self.assertEqual(inner[IP].src, self.pg2.remote_ip4)
self.assertEqual(inner[IP].dst, "172.16.3.3")
self.assert_ip_checksum_valid(inner)
@@ -438,7 +438,7 @@ class TestGSO(VppTestCase):
# IPv4/IPv6 - VXLAN
#
p65 = (
- Ether(src=self.pg2.remote_mac, dst="02:fe:60:1e:a2:79")
+ Ether(src=self.pg2.remote_mac, dst=self.pg2.local_mac)
/ IPv6(src=self.pg2.remote_ip6, dst="fd01:3::3")
/ TCP(sport=1234, dport=1234)
/ Raw(b"\xa5" * 65200)
@@ -452,12 +452,12 @@ class TestGSO(VppTestCase):
self.assertEqual(rx[IP].src, self.pg0.local_ip4)
self.assertEqual(rx[IP].dst, self.pg0.remote_ip4)
self.assert_ip_checksum_valid(rx)
- self.assert_udp_checksum_valid(rx, ignore_zero_checksum=False)
+ self.assert_udp_checksum_valid(rx, ignore_zero_checksum=True)
self.assertEqual(rx[VXLAN].vni, 10)
inner = rx[VXLAN].payload
self.assertEqual(rx[IP].len - 20 - 8 - 8, len(inner))
self.assertEqual(inner[Ether].src, self.pg2.remote_mac)
- self.assertEqual(inner[Ether].dst, "02:fe:60:1e:a2:79")
+ self.assertEqual(inner[Ether].dst, self.pg2.local_mac)
self.assertEqual(inner[IPv6].src, self.pg2.remote_ip6)
self.assertEqual(inner[IPv6].dst, "fd01:3::3")
self.assert_tcp_checksum_valid(inner)
@@ -483,7 +483,7 @@ class TestGSO(VppTestCase):
# IPv6/IPv4 - VXLAN
#
p46 = (
- Ether(src=self.pg2.remote_mac, dst="02:fe:60:1e:a2:79")
+ Ether(src=self.pg2.remote_mac, dst=self.pg2.local_mac)
/ IP(src=self.pg2.remote_ip4, dst="172.16.3.3", flags="DF")
/ TCP(sport=1234, dport=1234)
/ Raw(b"\xa5" * 65200)
@@ -501,7 +501,7 @@ class TestGSO(VppTestCase):
inner = rx[VXLAN].payload
self.assertEqual(rx[IPv6].plen - 8 - 8, len(inner))
self.assertEqual(inner[Ether].src, self.pg2.remote_mac)
- self.assertEqual(inner[Ether].dst, "02:fe:60:1e:a2:79")
+ self.assertEqual(inner[Ether].dst, self.pg2.local_mac)
self.assertEqual(inner[IP].src, self.pg2.remote_ip4)
self.assertEqual(inner[IP].dst, "172.16.3.3")
self.assert_ip_checksum_valid(inner)
@@ -515,7 +515,7 @@ class TestGSO(VppTestCase):
# IPv6/IPv6 - VXLAN
#
p66 = (
- Ether(src=self.pg2.remote_mac, dst="02:fe:60:1e:a2:79")
+ Ether(src=self.pg2.remote_mac, dst=self.pg2.local_mac)
/ IPv6(src=self.pg2.remote_ip6, dst="fd01:3::3")
/ TCP(sport=1234, dport=1234)
/ Raw(b"\xa5" * 65200)
@@ -533,7 +533,7 @@ class TestGSO(VppTestCase):
inner = rx[VXLAN].payload
self.assertEqual(rx[IPv6].plen - 8 - 8, len(inner))
self.assertEqual(inner[Ether].src, self.pg2.remote_mac)
- self.assertEqual(inner[Ether].dst, "02:fe:60:1e:a2:79")
+ self.assertEqual(inner[Ether].dst, self.pg2.local_mac)
self.assertEqual(inner[IPv6].src, self.pg2.remote_ip6)
self.assertEqual(inner[IPv6].dst, "fd01:3::3")
self.assert_tcp_checksum_valid(inner)
@@ -590,7 +590,7 @@ class TestGSO(VppTestCase):
# IPv4/IPv4 - IPIP
#
p47 = (
- Ether(src=self.pg2.remote_mac, dst="02:fe:60:1e:a2:79")
+ Ether(src=self.pg2.remote_mac, dst=self.pg2.local_mac)
/ IP(src=self.pg2.remote_ip4, dst="172.16.10.3", flags="DF")
/ TCP(sport=1234, dport=1234)
/ Raw(b"\xa5" * 65200)
@@ -633,7 +633,7 @@ class TestGSO(VppTestCase):
# IPv4/IPv6 - IPIP
#
p67 = (
- Ether(src=self.pg2.remote_mac, dst="02:fe:60:1e:a2:79")
+ Ether(src=self.pg2.remote_mac, dst=self.pg2.local_mac)
/ IPv6(src=self.pg2.remote_ip6, dst="fd01:10::3")
/ TCP(sport=1234, dport=1234)
/ Raw(b"\xa5" * 65200)
@@ -731,7 +731,7 @@ class TestGSO(VppTestCase):
# IPv6/IPv4 - IPIP
#
p48 = (
- Ether(src=self.pg2.remote_mac, dst="02:fe:60:1e:a2:79")
+ Ether(src=self.pg2.remote_mac, dst=self.pg2.local_mac)
/ IP(src=self.pg2.remote_ip4, dst="172.16.10.3", flags="DF")
/ TCP(sport=1234, dport=1234)
/ Raw(b"\xa5" * 65200)
@@ -774,7 +774,7 @@ class TestGSO(VppTestCase):
# IPv6/IPv6 - IPIP
#
p68 = (
- Ether(src=self.pg2.remote_mac, dst="02:fe:60:1e:a2:79")
+ Ether(src=self.pg2.remote_mac, dst=self.pg2.local_mac)
/ IPv6(src=self.pg2.remote_ip6, dst="fd01:10::3")
/ TCP(sport=1234, dport=1234)
/ Raw(b"\xa5" * 65200)
@@ -842,7 +842,7 @@ class TestGSO(VppTestCase):
self.ip4_via_gre4_tunnel.add_vpp_config()
pgre4 = (
- Ether(src=self.pg2.remote_mac, dst="02:fe:60:1e:a2:79")
+ Ether(src=self.pg2.remote_mac, dst=self.pg2.local_mac)
/ IP(src=self.pg2.remote_ip4, dst="172.16.10.3", flags="DF")
/ TCP(sport=1234, dport=1234)
/ Raw(b"\xa5" * 65200)
@@ -952,7 +952,7 @@ class TestGSO(VppTestCase):
# Create IPv6 packet
#
pgre6 = (
- Ether(src=self.pg2.remote_mac, dst="02:fe:60:1e:a2:79")
+ Ether(src=self.pg2.remote_mac, dst=self.pg2.local_mac)
/ IPv6(src=self.pg2.remote_ip6, dst="fd01:10::3")
/ TCP(sport=1234, dport=1234)
/ Raw(b"\xa5" * 65200)
@@ -1078,7 +1078,7 @@ class TestGSO(VppTestCase):
# IPv4/IPv4 - IPSEC
#
ipsec44 = (
- Ether(src=self.pg2.remote_mac, dst="02:fe:60:1e:a2:79")
+ Ether(src=self.pg2.remote_mac, dst=self.pg2.local_mac)
/ IP(src=self.pg2.remote_ip4, dst="172.16.10.3", flags="DF")
/ TCP(sport=1234, dport=1234)
/ Raw(b"\xa5" * 65200)
@@ -1116,7 +1116,7 @@ class TestGSO(VppTestCase):
# IPv4/IPv6 - IPSEC
#
ipsec46 = (
- Ether(src=self.pg2.remote_mac, dst="02:fe:60:1e:a2:79")
+ Ether(src=self.pg2.remote_mac, dst=self.pg2.local_mac)
/ IPv6(src=self.pg2.remote_ip6, dst="fd01:10::3")
/ TCP(sport=1234, dport=1234)
/ Raw(b"\xa5" * 65200)
@@ -1213,7 +1213,7 @@ class TestGSO(VppTestCase):
# IPv6/IPv4 - IPSEC
#
ipsec64 = (
- Ether(src=self.pg2.remote_mac, dst="02:fe:60:1e:a2:79")
+ Ether(src=self.pg2.remote_mac, dst=self.pg2.local_mac)
/ IP(src=self.pg2.remote_ip4, dst="172.16.10.3", flags="DF")
/ TCP(sport=1234, dport=1234)
/ Raw(b"\xa5" * 65200)
@@ -1252,7 +1252,7 @@ class TestGSO(VppTestCase):
# IPv6/IPv6 - IPSEC
#
ipsec66 = (
- Ether(src=self.pg2.remote_mac, dst="02:fe:60:1e:a2:79")
+ Ether(src=self.pg2.remote_mac, dst=self.pg2.local_mac)
/ IPv6(src=self.pg2.remote_ip6, dst="fd01:10::3")
/ TCP(sport=1234, dport=1234)
/ Raw(b"\xa5" * 65200)
diff --git a/test/test_gtpu.py b/test/test_gtpu.py
index fd97205ac63..5fe4f36ccb3 100644
--- a/test/test_gtpu.py
+++ b/test/test_gtpu.py
@@ -36,7 +36,7 @@ class TestGtpuUDP(VppTestCase):
def _check_udp_port_ip4(self, enabled=True):
pkt = (
- Ether(src=self.pg0.local_mac, dst=self.pg0.remote_mac)
+ Ether(src=self.pg0.remote_mac, dst=self.pg0.local_mac)
/ IP(src=self.pg0.remote_ip4, dst=self.pg0.local_ip4)
/ UDP(sport=self.dport, dport=self.dport, chksum=0)
)
@@ -55,7 +55,7 @@ class TestGtpuUDP(VppTestCase):
def _check_udp_port_ip6(self, enabled=True):
pkt = (
- Ether(src=self.pg0.local_mac, dst=self.pg0.remote_mac)
+ Ether(src=self.pg0.remote_mac, dst=self.pg0.local_mac)
/ IPv6(src=self.pg0.remote_ip6, dst=self.pg0.local_ip6)
/ UDP(sport=self.dport, dport=self.dport, chksum=0)
)
diff --git a/test/test_ip6.py b/test/test_ip6.py
index a1cd943570c..84b060aa7a3 100644
--- a/test/test_ip6.py
+++ b/test/test_ip6.py
@@ -3409,9 +3409,11 @@ class TestIP6LinkLocal(VppTestCase):
# Use the specific link-local API on pg1
#
VppIp6LinkLocalAddress(self, self.pg1, ll1).add_vpp_config()
+ p_echo_request_1.dst = self.pg1.local_mac
self.send_and_expect(self.pg1, [p_echo_request_1], self.pg1)
VppIp6LinkLocalAddress(self, self.pg1, ll3).add_vpp_config()
+ p_echo_request_3.dst = self.pg1.local_mac
self.send_and_expect(self.pg1, [p_echo_request_3], self.pg1)
def test_ip6_ll_p2p(self):
diff --git a/test/test_ip6_nd_mirror_proxy.py b/test/test_ip6_nd_mirror_proxy.py
index 65209925e87..10dc77e1a86 100644
--- a/test/test_ip6_nd_mirror_proxy.py
+++ b/test/test_ip6_nd_mirror_proxy.py
@@ -161,7 +161,7 @@ class TestNDPROXY(VppTestCase):
redirect.add_vpp_config()
echo_reply = (
- Ether(dst=self.pg0.remote_mac, src=self.pg0.local_mac)
+ Ether(dst=self.pg0.local_mac, src=self.pg0.remote_mac)
/ IPv6(dst=self.pg0.local_ip6, src=self.pg0.remote_ip6)
/ ICMPv6EchoReply(seq=1, id=id)
)
diff --git a/test/test_ipip.py b/test/test_ipip.py
index 2817d5a17ba..9574c2c299c 100644
--- a/test/test_ipip.py
+++ b/test/test_ipip.py
@@ -677,7 +677,7 @@ class TestIPIP(VppTestCase):
/ Raw(b"0x44" * 100)
)
tx_e = [
- (Ether(dst=self.pg0.local_mac, src=self.pg0.remote_mac) / inner)
+ (Ether(dst=self.pg2.local_mac, src=self.pg0.remote_mac) / inner)
for x in range(63)
]
@@ -1454,7 +1454,7 @@ class TestIPIPMPLS(VppTestCase):
# Tunnel Decap
#
p4 = (
- self.p_ether
+ Ether(src=self.pg1.remote_mac, dst=self.pg1.local_mac)
/ IP(src=self.pg1.remote_ip4, dst=self.pg1.local_ip4)
/ MPLS(label=44, ttl=4)
/ IP(src="1.1.1.1", dst="2.2.2.2")
@@ -1468,7 +1468,7 @@ class TestIPIPMPLS(VppTestCase):
self.assertEqual(rx[IP].dst, "2.2.2.2")
p6 = (
- self.p_ether
+ Ether(src=self.pg1.remote_mac, dst=self.pg1.local_mac)
/ IPv6(src=self.pg1.remote_ip6, dst=self.pg1.local_ip6)
/ MPLS(label=66, ttl=4)
/ IPv6(src="1::1", dst="2::2")
diff --git a/test/test_l3xc.py b/test/test_l3xc.py
index 351c599051c..69267b35817 100644
--- a/test/test_l3xc.py
+++ b/test/test_l3xc.py
@@ -126,7 +126,7 @@ class TestL3xc(VppTestCase):
p_2 = []
for ii in range(NUM_PKTS):
p_2.append(
- Ether(src=self.pg0.remote_mac, dst=self.pg0.local_mac)
+ Ether(src=self.pg2.remote_mac, dst=self.pg2.local_mac)
/ IP(src="1.1.1.1", dst="1.1.1.2")
/ UDP(sport=1000 + ii, dport=1234)
/ Raw(b"\xa5" * 100)
diff --git a/test/test_linux_cp.py b/test/test_linux_cp.py
index a9ff242e215..95a9f1aca1f 100644
--- a/test/test_linux_cp.py
+++ b/test/test_linux_cp.py
@@ -126,7 +126,7 @@ class TestLinuxCP(VppTestCase):
for phy, host in zip(phys, hosts):
for j in range(N_HOSTS):
p = (
- Ether(src=phy.local_mac, dst=phy.remote_hosts[j].mac)
+ Ether(src=phy.local_mac, dst=host.local_mac)
/ IP(src=phy.local_ip4, dst=phy.remote_hosts[j].ip4)
/ UDP(sport=1234, dport=1234)
/ Raw()
diff --git a/test/test_map.py b/test/test_map.py
index 565f7da6491..c65c5df7cda 100644
--- a/test/test_map.py
+++ b/test/test_map.py
@@ -494,7 +494,7 @@ class TestMAP(VppTestCase):
#
# Send a v4 packet that will be encapped.
#
- p_ether = Ether(dst=self.pg0.local_mac, src=self.pg0.remote_mac)
+ p_ether = Ether(dst=self.pg1.local_mac, src=self.pg1.remote_mac)
p_ip4 = IP(src=self.pg0.remote_ip4, dst="192.168.1.1")
p_tcp = TCP(sport=20000, dport=30000, flags="S", options=[("MSS", 1455)])
p4 = p_ether / p_ip4 / p_tcp
diff --git a/test/test_map_br.py b/test/test_map_br.py
index 0de0e31520c..a2c00d8d8ea 100644
--- a/test/test_map_br.py
+++ b/test/test_map_br.py
@@ -280,7 +280,7 @@ class TestMAPBR(VppTestCase):
def test_map_t_echo_request_ip4_to_ip6(self):
"""MAP-T echo request IPv4 -> IPv6"""
- eth = Ether(src=self.pg1.remote_mac, dst=self.pg1.local_mac)
+ eth = Ether(src=self.pg0.remote_mac, dst=self.pg0.local_mac)
ip = IP(src=self.pg0.remote_ip4, dst=self.ipv4_map_address)
icmp = ICMP(type="echo-request", id=self.ipv6_udp_or_tcp_map_port)
payload = "H" * 10
@@ -306,7 +306,7 @@ class TestMAPBR(VppTestCase):
def test_map_t_echo_reply_ip4_to_ip6(self):
"""MAP-T echo reply IPv4 -> IPv6"""
- eth = Ether(src=self.pg1.remote_mac, dst=self.pg1.local_mac)
+ eth = Ether(src=self.pg0.remote_mac, dst=self.pg0.local_mac)
ip = IP(src=self.pg0.remote_ip4, dst=self.ipv4_map_address)
icmp = ICMP(type="echo-reply", id=self.ipv6_udp_or_tcp_map_port)
payload = "H" * 10
diff --git a/test/test_mpls.py b/test/test_mpls.py
index 9c07251a481..0e747ec7cd0 100644
--- a/test/test_mpls.py
+++ b/test/test_mpls.py
@@ -2018,7 +2018,7 @@ class TestMPLS(VppTestCase):
binding.add_vpp_config()
tx = (
- Ether(src=self.pg1.remote_mac, dst=self.pg1.local_mac)
+ Ether(src=self.pg0.remote_mac, dst=self.pg0.local_mac)
/ MPLS(label=44, ttl=64)
/ IP(src=self.pg0.remote_ip4, dst=self.pg0.remote_ip4)
/ UDP(sport=1234, dport=1234)
diff --git a/test/test_nat44_ed_output.py b/test/test_nat44_ed_output.py
index ad1c5611418..dbf1dc40a75 100644
--- a/test/test_nat44_ed_output.py
+++ b/test/test_nat44_ed_output.py
@@ -216,7 +216,7 @@ class TestNAT44EDOutput(VppTestCase):
# send FIN+ACK packet in->out - will cause session to be wiped
# but won't create a new session
p = (
- Ether(src=pg0.remote_mac, dst=pg0.local_mac)
+ Ether(src=pg1.remote_mac, dst=pg1.local_mac)
/ IP(src=local_host, dst=remote_host)
/ TCP(sport=local_sport, dport=remote_dport, flags="FA", seq=300, ack=101)
)
diff --git a/test/test_neighbor.py b/test/test_neighbor.py
index 6fcf13f8261..d11d4abac14 100644
--- a/test/test_neighbor.py
+++ b/test/test_neighbor.py
@@ -2176,6 +2176,7 @@ class ARPTestCase(VppTestCase):
table_id=1,
).add_vpp_config()
+ p2.dst = self.pg3.local_mac
rxs = self.send_and_expect(self.pg3, [p2], self.pg1)
for rx in rxs:
self.verify_arp_req(rx, self.pg1.local_mac, "10.0.1.2", "10.0.1.128")
diff --git a/test/test_pcap.py b/test/test_pcap.py
index ae3a298f76a..72d215cea06 100644
--- a/test/test_pcap.py
+++ b/test/test_pcap.py
@@ -135,7 +135,7 @@ class TestPcap(VppTestCase):
self.vapi.cli("classify filter pcap del mask l3 ip4 src")
pkt = (
- Ether(src=self.pg0.local_mac, dst=self.pg0.remote_mac)
+ Ether(src=self.pg0.remote_mac, dst=self.pg0.local_mac)
# wrong destination address
/ IP(src=self.pg0.local_ip4, dst=self.pg0.local_ip4, ttl=2)
/ UDP(sport=1234, dport=2345)
diff --git a/test/test_reassembly.py b/test/test_reassembly.py
index e407252d380..98c50f9bb61 100644
--- a/test/test_reassembly.py
+++ b/test/test_reassembly.py
@@ -1604,16 +1604,6 @@ class TestIPv6Reassembly(VppTestCase):
self.assertIn(ICMPv6ParamProblem, icmp)
self.assert_equal(icmp[ICMPv6ParamProblem].code, 3, "ICMP code")
- def test_truncated_fragment(self):
- """truncated fragment"""
- pkt = (
- Ether(src=self.pg0.local_mac, dst=self.pg0.remote_mac)
- / IPv6(src=self.pg0.remote_ip6, dst=self.pg0.local_ip6, nh=44, plen=2)
- / IPv6ExtHdrFragment(nh=6)
- )
-
- self.send_and_assert_no_replies(self.pg0, [pkt], self.pg0)
-
def test_invalid_frag_size(self):
"""fragment size not a multiple of 8"""
p = (
@@ -1657,7 +1647,7 @@ class TestIPv6Reassembly(VppTestCase):
def test_atomic_fragment(self):
"""IPv6 atomic fragment"""
pkt = (
- Ether(src=self.pg0.local_mac, dst=self.pg0.remote_mac)
+ Ether(src=self.pg0.remote_mac, dst=self.pg0.local_mac)
/ IPv6(src=self.pg0.remote_ip6, dst=self.pg0.local_ip6, nh=44, plen=65535)
/ IPv6ExtHdrFragment(
offset=8191, m=1, res1=0xFF, res2=0xFF, nh=255, id=0xFFFF
@@ -1679,7 +1669,7 @@ class TestIPv6Reassembly(VppTestCase):
self.send_and_assert_no_replies(self.pg0, [pkt])
pkt = (
- Ether(src=self.pg0.local_mac, dst=self.pg0.remote_mac)
+ Ether(src=self.pg0.remote_mac, dst=self.pg0.local_mac)
/ IPv6(src=self.pg0.remote_ip6, dst=self.pg0.remote_ip6)
/ ICMPv6EchoRequest()
)
@@ -1688,7 +1678,7 @@ class TestIPv6Reassembly(VppTestCase):
def test_one_fragment(self):
"""whole packet in one fragment processed independently"""
pkt = (
- Ether(src=self.pg0.local_mac, dst=self.pg0.remote_mac)
+ Ether(src=self.pg0.remote_mac, dst=self.pg0.local_mac)
/ IPv6(src=self.pg0.remote_ip6, dst=self.pg0.local_ip6)
/ ICMPv6EchoRequest()
/ Raw("X" * 1600)
@@ -1700,7 +1690,7 @@ class TestIPv6Reassembly(VppTestCase):
# send an atomic fragment with same id - should be reassembled
pkt = (
- Ether(src=self.pg0.local_mac, dst=self.pg0.remote_mac)
+ Ether(src=self.pg0.remote_mac, dst=self.pg0.local_mac)
/ IPv6(src=self.pg0.remote_ip6, dst=self.pg0.local_ip6)
/ IPv6ExtHdrFragment(id=1)
/ ICMPv6EchoRequest()
@@ -1715,7 +1705,7 @@ class TestIPv6Reassembly(VppTestCase):
def test_bunch_of_fragments(self):
"""valid fragments followed by rogue fragments and atomic fragment"""
pkt = (
- Ether(src=self.pg0.local_mac, dst=self.pg0.remote_mac)
+ Ether(src=self.pg0.remote_mac, dst=self.pg0.local_mac)
/ IPv6(src=self.pg0.remote_ip6, dst=self.pg0.local_ip6)
/ ICMPv6EchoRequest()
/ Raw("X" * 1600)
@@ -1733,7 +1723,7 @@ class TestIPv6Reassembly(VppTestCase):
self.send_and_assert_no_replies(self.pg0, inc_frag * 604)
pkt = (
- Ether(src=self.pg0.local_mac, dst=self.pg0.remote_mac)
+ Ether(src=self.pg0.remote_mac, dst=self.pg0.local_mac)
/ IPv6(src=self.pg0.remote_ip6, dst=self.pg0.local_ip6)
/ IPv6ExtHdrFragment(id=1)
/ ICMPv6EchoRequest()
@@ -1748,7 +1738,7 @@ class TestIPv6Reassembly(VppTestCase):
)
self.vapi.ip_local_reass_enable_disable(enable_ip6=True)
pkt = (
- Ether(src=self.src_if.local_mac, dst=self.src_if.remote_mac)
+ Ether(src=self.src_if.remote_mac, dst=self.src_if.local_mac)
/ IPv6(src=self.src_if.remote_ip6, dst=self.src_if.local_ip6)
/ ICMPv6EchoRequest(id=1234)
/ Raw("X" * 1600)
@@ -2194,7 +2184,7 @@ class TestIPv6SVReassembly(VppTestCase):
def test_one_fragment(self):
"""whole packet in one fragment processed independently"""
pkt = (
- Ether(src=self.src_if.local_mac, dst=self.src_if.remote_mac)
+ Ether(src=self.src_if.remote_mac, dst=self.src_if.local_mac)
/ IPv6(src=self.src_if.remote_ip6, dst=self.dst_if.remote_ip6)
/ ICMPv6EchoRequest()
/ Raw("X" * 1600)
@@ -2206,7 +2196,7 @@ class TestIPv6SVReassembly(VppTestCase):
# send an atomic fragment with same id - should be reassembled
pkt = (
- Ether(src=self.src_if.local_mac, dst=self.src_if.remote_mac)
+ Ether(src=self.src_if.remote_mac, dst=self.src_if.local_mac)
/ IPv6(src=self.src_if.remote_ip6, dst=self.dst_if.remote_ip6)
/ IPv6ExtHdrFragment(id=1)
/ ICMPv6EchoRequest()
@@ -2219,7 +2209,7 @@ class TestIPv6SVReassembly(VppTestCase):
def test_bunch_of_fragments(self):
"""valid fragments followed by rogue fragments and atomic fragment"""
pkt = (
- Ether(src=self.src_if.local_mac, dst=self.src_if.remote_mac)
+ Ether(src=self.src_if.remote_mac, dst=self.src_if.local_mac)
/ IPv6(src=self.src_if.remote_ip6, dst=self.dst_if.remote_ip6)
/ ICMPv6EchoRequest()
/ Raw("X" * 1600)
@@ -2228,7 +2218,7 @@ class TestIPv6SVReassembly(VppTestCase):
rx = self.send_and_expect(self.src_if, frags, self.dst_if)
rogue = (
- Ether(src=self.src_if.local_mac, dst=self.src_if.remote_mac)
+ Ether(src=self.src_if.remote_mac, dst=self.src_if.local_mac)
/ IPv6(src=self.src_if.remote_ip6, dst=self.dst_if.remote_ip6)
/ IPv6ExtHdrFragment(id=1, nh=58, offset=608)
/ Raw("X" * 308)
@@ -2237,7 +2227,7 @@ class TestIPv6SVReassembly(VppTestCase):
self.send_and_expect(self.src_if, rogue * 604, self.dst_if)
pkt = (
- Ether(src=self.src_if.local_mac, dst=self.src_if.remote_mac)
+ Ether(src=self.src_if.remote_mac, dst=self.src_if.local_mac)
/ IPv6(src=self.src_if.remote_ip6, dst=self.dst_if.remote_ip6)
/ IPv6ExtHdrFragment(id=1)
/ ICMPv6EchoRequest()
diff --git a/test/test_srv6_mobile.py b/test/test_srv6_mobile.py
index 9d39f194015..314dfc114e2 100644
--- a/test/test_srv6_mobile.py
+++ b/test/test_srv6_mobile.py
@@ -60,7 +60,7 @@ class TestSRv6EndMGTP4E(VppTestCase):
pkts = list()
for d, s in inner:
pkt = (
- Ether()
+ Ether(dst=self.pg0.local_mac)
/ IPv6(dst=str(ip6_dst), src=str(ip6_src))
/ IPv6ExtHdrSegmentRouting()
/ IPv6(dst=d, src=s)
@@ -149,7 +149,7 @@ class TestSRv6TMGTP4D(VppTestCase):
pkts = list()
for d, s in inner:
pkt = (
- Ether()
+ Ether(dst=self.pg0.local_mac)
/ IP(dst=str(ip4_dst), src=str(ip4_src))
/ UDP(sport=2152, dport=2152)
/ GTP_U_Header(gtp_type="g_pdu", teid=200)
@@ -254,7 +254,7 @@ class TestSRv6EndMGTP6E(VppTestCase):
pkts = list()
for d, s in inner:
pkt = (
- Ether()
+ Ether(dst=self.pg0.local_mac)
/ IPv6(dst=str(ip6_dst), src=str(ip6_src))
/ IPv6ExtHdrSegmentRouting(
segleft=1, lastentry=0, tag=0, addresses=["a1::1"]
@@ -344,7 +344,7 @@ class TestSRv6EndMGTP6D(VppTestCase):
pkts = list()
for d, s in inner:
pkt = (
- Ether()
+ Ether(dst=self.pg0.local_mac)
/ IPv6(dst=str(ip6_dst), src=str(ip6_src))
/ UDP(sport=2152, dport=2152)
/ GTP_U_Header(gtp_type="g_pdu", teid=200)
diff --git a/test/test_trace_filter.py b/test/test_trace_filter.py
index 58494cd7ad9..c188631c200 100644
--- a/test/test_trace_filter.py
+++ b/test/test_trace_filter.py
@@ -386,7 +386,7 @@ class TestTraceFilterInner(TemplateTraceFilter):
def __gen_encrypt_pkt(self, scapy_sa, pkt):
return Ether(
- src=self.pg0.local_mac, dst=self.pg0.remote_mac
+ src=self.pg0.remote_mac, dst=self.pg0.local_mac
) / scapy_sa.encrypt(pkt)
def test_encrypted_encap(self):
diff --git a/test/test_vxlan.py b/test/test_vxlan.py
index 6128d1070d3..284e1359116 100644
--- a/test/test_vxlan.py
+++ b/test/test_vxlan.py
@@ -580,6 +580,7 @@ class TestVxlanL2Mode(VppTestCase):
# Send packets
NUM_PKTS = 128
+ p.dst = self.pg1.local_mac
rx = self.send_and_expect(self.pg1, p * NUM_PKTS, self.pg0)
self.assertEqual(NUM_PKTS, len(rx))