[V2] tests/l3fwd_func: fix script

Message ID 20220517074859.1715527-1-songx.jiale@intel.com (mailing list archive)
State Accepted
Headers
Series [V2] tests/l3fwd_func: fix script |

Checks

Context Check Description
ci/Intel-dts-format-test success Testing OK
ci/Intel-dts-pylama-test success Testing OK
ci/Intel-dts-suite-test fail Testing issues

Commit Message

Jiale, SongX May 17, 2022, 7:48 a.m. UTC
  fix 2 issue:
  1.When DUT and tester ports are cross connected, the information of interconnection 
    ports cannot be obtained correctly.
  2.tcpdump timeout, increase the '-n' to skip the tcpdump reverse domain name 
    resolution operation.

Signed-off-by: Jiale Song <songx.jiale@intel.com>
---
 tests/TestSuite_l3fwd_func.py | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
  

Comments

Lingli Chen May 17, 2022, 8:22 a.m. UTC | #1
> -----Original Message-----
> From: Jiale Song <songx.jiale@intel.com>
> Sent: Tuesday, May 17, 2022 3:49 PM
> To: dts@dpdk.org
> Cc: Jiale, SongX <songx.jiale@intel.com>
> Subject: [dts] [PATCH V2] tests/l3fwd_func: fix script
> 
> fix 2 issue:
>   1.When DUT and tester ports are cross connected, the information of
> interconnection
>     ports cannot be obtained correctly.
>   2.tcpdump timeout, increase the '-n' to skip the tcpdump reverse domain
> name
>     resolution operation.
> 
> Signed-off-by: Jiale Song <songx.jiale@intel.com>
> ---

Tested-by: Lingli Chen <linglix.chen@intel.com>
  
Tu, Lijuan May 18, 2022, 8:58 a.m. UTC | #2
On Tue, 17 May 2022 15:48:59 +0800, Jiale Song <songx.jiale@intel.com> wrote:
> fix 2 issue:
>   1.When DUT and tester ports are cross connected, the information of interconnection 
>     ports cannot be obtained correctly.
>   2.tcpdump timeout, increase the '-n' to skip the tcpdump reverse domain name 
>     resolution operation.
> 
> Signed-off-by: Jiale Song <songx.jiale@intel.com>


Applied, thanks
  

Patch

diff --git a/tests/TestSuite_l3fwd_func.py b/tests/TestSuite_l3fwd_func.py
index 7340c09d..c2a3988b 100644
--- a/tests/TestSuite_l3fwd_func.py
+++ b/tests/TestSuite_l3fwd_func.py
@@ -49,7 +49,8 @@  class TestL3fwdFunc(TestCase):
         self.app_path = self.dut.build_dpdk_apps("examples/l3fwd")
         self.pkt = Packet()
         self.dport_info0 = self.dut.ports_info[self.dut_ports[0]]
-        self.tport_info0 = self.tester.ports_info[self.dut_ports[0]]
+        tport = self.tester.get_local_port(self.dut_ports[0])
+        self.tport_info0 = self.tester.ports_info[tport]
         self.tport_intf0 = self.tport_info0["intf"]
         # judgment is added to avoid errors caused by the absence of port 1
         if len(self.dut_ports) >= 2:
@@ -132,7 +133,7 @@  class TestL3fwdFunc(TestCase):
         :return:
         """
         out = self.tester.send_expect(
-            "tcpdump -r /tmp/tester/sniff_%s.pcap" % (self.tport_intf0),
+            "tcpdump -n -r /tmp/tester/sniff_%s.pcap" % (self.tport_intf0),
             "# ",
             timeout=30,
         )