test suite reviews and discussions
 help / color / mirror / Atom feed
From: "Tu, Lijuan" <lijuan.tu@intel.com>
To: "Li, WenjieX A" <wenjiex.a.li@intel.com>, "dts@dpdk.org" <dts@dpdk.org>
Cc: "Li, WenjieX A" <wenjiex.a.li@intel.com>
Subject: Re: [dts] [PATCH V1] tests/tso: should stop ports before set csum
Date: Wed, 22 May 2019 05:54:41 +0000	[thread overview]
Message-ID: <8CE3E05A3F976642AAB0F4675D0AD20E0BA84060@SHSMSX101.ccr.corp.intel.com> (raw)
In-Reply-To: <1558056527-52378-1-git-send-email-wenjiex.a.li@intel.com>

Applied, thanks

> -----Original Message-----
> From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of Wenjie Li
> Sent: Friday, May 17, 2019 9:29 AM
> To: dts@dpdk.org
> Cc: Li, WenjieX A <wenjiex.a.li@intel.com>
> Subject: [dts] [PATCH V1] tests/tso: should stop ports before set csum
> 
> 1. should stop ports before set csum and start ports after the settings 2.
> there is no clear indication of which network card is not supported, will not
> check the nic type anymore 3. add tear_down and tear_down_all 4. delete
> unless comment/code
> 
> Signed-off-by: Wenjie Li <wenjiex.a.li@intel.com>
> ---
>  tests/TestSuite_tso.py | 33 ++++++++++++++++++---------------
>  1 file changed, 18 insertions(+), 15 deletions(-)
> 
> diff --git a/tests/TestSuite_tso.py b/tests/TestSuite_tso.py index
> 6735169..5e0dbd5 100644
> --- a/tests/TestSuite_tso.py
> +++ b/tests/TestSuite_tso.py
> @@ -51,13 +51,6 @@ class TestTSO(TestCase):
>          """
>          Run at the start of each test suite.
>          """
> -        # this feature support Fortville, Niantic
> -        self.verify(self.nic in ["kawela_2", "niantic", "bartonhills", "82545EM",
> -                                 "82540EM", "springfountain", "fortville_eagle",
> -                                 "fortville_spirit", "fortville_spirit_single",
> -                                 "redrockcanyou", "atwood", "boulderrapid",
> "fortpark_TLV","fortville_25g","hi1822", "cavium_a063"],
> -                    "NIC Unsupported: " + str(self.nic))
> -
>          # Based on h/w type, choose how many ports to use
>          self.dut_ports = self.dut.get_ports(self.nic)
> 
> @@ -72,12 +65,6 @@ class TestTSO(TestCase):
>          self.frame_sizes = [128, 1458]
>          self.rxfreet_values = [0, 8, 16, 32, 64, 128]
> 
> -        # self.test_cycles = [{'cores': '1S/1C/1T', 'Mpps': {}, 'pct': {}},
> -        #                     {'cores': '1S/1C/2T', 'Mpps': {}, 'pct': {}},
> -        #                     {'cores': '1S/2C/1T', 'Mpps': {}, 'pct': {}},
> -        #                     {'cores': '1S/2C/2T', 'Mpps': {}, 'pct': {}},
> -        #                     {'cores': '1S/4C/2T', 'Mpps': {}, 'pct': {}}
> -        #                     ]
>          self.test_cycles = [{'cores': '1S/1C/2T', 'Mpps': {}, 'pct': {}}]
> 
>          self.table_header = ['Frame Size'] @@ -87,8 +74,6 @@ class
> TestTSO(TestCase):
> 
>          self.blacklist = ""
> 
> -        # self.coreMask = utils.create_mask(cores)
> -
>          self.headers_size = HEADER_SIZE['eth'] + HEADER_SIZE[
>              'ip'] + HEADER_SIZE['tcp']
> 
> @@ -160,6 +145,7 @@ class TestTSO(TestCase):
>          cmd = "./%s/app/testpmd -c %s -n %d %s -- -i --rxd=512 --txd=512 --
> burst=32 --rxfreet=64 --mbcache=128 --portmask=%s --txpt=36 --txht=0 --
> txwt=0 --txfreet=32 --txrst=32 " % (self.target, self.coreMask,
> self.dut.get_memory_channels(), self.blacklist, self.portMask)
>          self.dut.send_expect(cmd, "testpmd> ", 120)
>          self.dut.send_expect("set verbose 1", "testpmd> ", 120)
> +        self.dut.send_expect("port stop all", "testpmd> ", 120)
>          self.dut.send_expect("csum set ip hw %d" % self.dut_ports[0], "testpmd>
> ", 120)
>          self.dut.send_expect("csum set udp hw %d" % self.dut_ports[0],
> "testpmd> ", 120)
>          self.dut.send_expect("csum set tcp hw %d" % self.dut_ports[0],
> "testpmd> ", 120) @@ -176,6 +162,7 @@ class TestTSO(TestCase):
> 
>          self.dut.send_expect("tso set 800 %d" % self.dut_ports[1], "testpmd> ",
> 120)
>          self.dut.send_expect("set fwd csum", "testpmd> ", 120)
> +        self.dut.send_expect("port start all", "testpmd> ", 120)
>          self.dut.send_expect("start", "testpmd> ")
> 
>          self.tester.scapy_foreground()
> @@ -226,6 +213,7 @@ class TestTSO(TestCase):
>          cmd = "./%s/app/testpmd -c %s -n %d %s -- -i --rxd=512 --txd=512 --
> burst=32 --rxfreet=64 --mbcache=128 --portmask=%s --txpt=36 --txht=0 --
> txwt=0 --txfreet=32 --txrst=32 " % (self.target, self.coreMask,
> self.dut.get_memory_channels(), self.blacklist, self.portMask)
>          self.dut.send_expect(cmd, "testpmd> ", 120)
>          self.dut.send_expect("set verbose 1", "testpmd> ", 120)
> +        self.dut.send_expect("port stop all", "testpmd> ", 120)
>          self.dut.send_expect("csum set ip hw %d" % self.dut_ports[0], "testpmd>
> ", 120)
>          self.dut.send_expect("csum set udp hw %d" % self.dut_ports[0],
> "testpmd> ", 120)
>          self.dut.send_expect("csum set tcp hw %d" % self.dut_ports[0],
> "testpmd> ", 120) @@ -242,6 +230,7 @@ class TestTSO(TestCase):
> 
>          self.dut.send_expect("tso set 800 %d" % self.dut_ports[1], "testpmd> ",
> 120)
>          self.dut.send_expect("set fwd csum", "testpmd> ", 120)
> +        self.dut.send_expect("port start all", "testpmd> ", 120)
>          self.dut.send_expect("start", "testpmd> ")
> 
>          self.tester.scapy_foreground()
> @@ -295,6 +284,7 @@ class TestTSO(TestCase):
>              self.rst_report(command_line + "\n\n", frame=True, annex=True)
> 
>              self.dut.send_expect(command_line, "testpmd> ", 120)
> +            self.dut.send_expect("port stop all", "testpmd> ", 120)
>              self.dut.send_expect("csum set ip hw %d" % self.dut_ports[0],
> "testpmd> ", 120)
>              self.dut.send_expect("csum set udp hw %d" % self.dut_ports[0],
> "testpmd> ", 120)
>              self.dut.send_expect("csum set tcp hw %d" % self.dut_ports[0],
> "testpmd> ", 120) @@ -309,6 +299,7 @@ class TestTSO(TestCase):
>              self.dut.send_expect("csum parse-tunnel on %d" % self.dut_ports[1],
> "testpmd> ", 120)
>              self.dut.send_expect("tso set 800 %d" % self.dut_ports[1], "testpmd>
> ", 120)
>              self.dut.send_expect("set fwd csum", "testpmd> ", 120)
> +            self.dut.send_expect("port start all", "testpmd> ", 120)
>              self.dut.send_expect("start", "testpmd> ")
>              for frame_size in self.frame_sizes:
>                  wirespeed = self.wirespeed(self.nic, frame_size, 2) @@ -350,3
> +341,15 @@ class TestTSO(TestCase):
>              self.result_table_add(table_row)
> 
>          self.result_table_print()
> +    def tear_down(self):
> +        """
> +        Run after each test case.
> +        """
> +        self.dut.kill_all()
> +        time.sleep(2)
> +
> +    def tear_down_all(self):
> +        """
> +        Run after each test suite.
> +        """
> +        pass
> --
> 2.17.2


      parent reply	other threads:[~2019-05-22  5:54 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-17  1:28 Wenjie Li
2019-05-17  1:26 ` Li, WenjieX A
2019-05-17  1:26 ` Li, WenjieX A
2019-05-22  5:54 ` Tu, Lijuan [this message]

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=8CE3E05A3F976642AAB0F4675D0AD20E0BA84060@SHSMSX101.ccr.corp.intel.com \
    --to=lijuan.tu@intel.com \
    --cc=dts@dpdk.org \
    --cc=wenjiex.a.li@intel.com \
    /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).