From: Wei Ling <weix.ling@intel.com>
To: dts@dpdk.org
Cc: Wei Ling <weix.ling@intel.com>
Subject: [dts][PATCH V1] tests/virtio_user_as_exceptional_path: modify testsuite syncwith testplan
Date: Mon, 26 Sep 2022 05:27:42 -0400 [thread overview]
Message-ID: <20220926092742.129203-1-weix.ling@intel.com> (raw)
1.Combin testcase1 and testcase1 into one case sync with testplan.
2.Delete the redundant steps and add the steps sync with testplan.
Signed-off-by: Wei Ling <weix.ling@intel.com>
---
...stSuite_virtio_user_as_exceptional_path.py | 33 +++++--------------
1 file changed, 8 insertions(+), 25 deletions(-)
diff --git a/tests/TestSuite_virtio_user_as_exceptional_path.py b/tests/TestSuite_virtio_user_as_exceptional_path.py
index c5105d5f..509d63f3 100644
--- a/tests/TestSuite_virtio_user_as_exceptional_path.py
+++ b/tests/TestSuite_virtio_user_as_exceptional_path.py
@@ -139,10 +139,11 @@ class TestVirtioUserAsExceptionalPath(TestCase):
self.vhost_user.send_expect(
"port config 0 tx_offload ipv4_cksum on", "testpmd> ", 120
)
+ self.vhost_user.send_expect("csum set tcp hw 0", "testpmd> ", 120)
+ self.vhost_user.send_expect("csum set ip hw 0", "testpmd> ", 120)
self.vhost_user.send_expect("csum set ip sw 1", "testpmd> ", 120)
self.vhost_user.send_expect("csum set tcp hw 1", "testpmd> ", 120)
- self.vhost_user.send_expect("csum set ip hw 0", "testpmd> ", 120)
- self.vhost_user.send_expect("csum set tcp hw 0", "testpmd> ", 120)
+ self.vhost_user.send_expect("set port 0 gso on", "testpmd> ", 120)
self.vhost_user.send_expect("tso set 1448 0", "testpmd> ", 120)
self.vhost_user.send_expect("port start 0", "testpmd> ", 120)
self.vhost_user.send_expect("port start 1", "testpmd> ", 120)
@@ -173,12 +174,6 @@ class TestVirtioUserAsExceptionalPath(TestCase):
self.dut.send_expect(
"ip netns exec ns1 ifconfig %s 1.1.1.8 up" % self.nic_in_kernel, "#"
)
- self.dut.send_expect(
- "ip netns exec ns1 ethtool -K %s gro on" % self.nic_in_kernel, "#"
- )
- self.dut.send_expect(
- "ip netns exec ns1 ethtool -K %s tso on" % self.nic_in_kernel, "#"
- )
def iperf_result_verify(self, vm_client, direction):
"""
@@ -258,11 +253,13 @@ class TestVirtioUserAsExceptionalPath(TestCase):
rate_value > 0, "The received package did not reach the expected value"
)
- def test_vhost_exception_path_TAP_original(self):
+ def test_vhost_exception_path_with_virtio_user(self):
+ """
+ Test Case1:test exceptional path with virtio_user
+ """
self.get_pci_info_from_cfg()
self.config_kernel_nic_host()
self.launch_testpmd_exception_path()
- self.dut.get_session_output(timeout=2)
time.sleep(5)
# Get the virtio-net device name
self.prepare_tap_device()
@@ -278,21 +275,7 @@ class TestVirtioUserAsExceptionalPath(TestCase):
self.iperf_result_verify(self.iperf, "direction_TAP_original")
self.logger.info("TAP->virtio-user->Kernel_NIC %s " % (self.output_result))
self.iperf.send_expect("rm /root/iperf_client.log", "#", 10)
- self.vhost_user.send_expect("quit", "#", 120)
- self.dut.close_session(self.vhost_user)
- self.dut.send_expect("ip netns del ns1", "#")
- self.dut.close_session(self.iperf)
- def test_vhost_exception_path_NIC_original(self):
- self.get_pci_info_from_cfg()
- self.config_kernel_nic_host()
- self.launch_testpmd_exception_path()
- time.sleep(5)
- self.dut.get_session_output(timeout=2)
- self.prepare_tap_device()
- self.testpmd_reset()
- self.iperf = self.dut.new_session(suite="iperf")
- self.dut.send_expect("rm /root/iperf_client.log", "#", 10)
self.iperf.send_expect("iperf -s -i 1", "", 180)
self.dut.send_expect(
"ip netns exec ns1 iperf -c 1.1.1.2 -i 1 -t 10 > /root/iperf_client.log &",
@@ -302,9 +285,9 @@ class TestVirtioUserAsExceptionalPath(TestCase):
time.sleep(30)
self.iperf.send_expect("^C", "#", 10)
self.iperf_result_verify(self.dut, "direction_NIC_original")
- self.dut.get_session_output(timeout=2)
self.logger.info("Kernel_NIC<-virtio-user<-TAP %s " % (self.output_result))
self.dut.send_expect("rm /root/iperf_client.log", "#", 10)
+
self.vhost_user.send_expect("quit", "#", 120)
self.dut.close_session(self.vhost_user)
self.dut.send_expect("ip netns del ns1", "#")
--
2.25.1
reply other threads:[~2022-09-26 9:35 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220926092742.129203-1-weix.ling@intel.com \
--to=weix.ling@intel.com \
--cc=dts@dpdk.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).