test suite reviews and discussions
 help / color / mirror / Atom feed
* [dts] [PATCH V1] tests/TestSuite_vlan_ethertype_config.py :stop port before set tx_vlan
@ 2018-02-08  8:04 zhu,shuai
  2018-02-11 10:25 ` Liu, Yong
  0 siblings, 1 reply; 2+ messages in thread
From: zhu,shuai @ 2018-02-08  8:04 UTC (permalink / raw)
  To: dts; +Cc: zhu,shuai

diff --git a/tests/TestSuite_vlan_ethertype_config.py b/tests/TestSuite_vlan_ethertype_config.py
index 8e6dd49..1fb30fb 100644
--- a/tests/TestSuite_vlan_ethertype_config.py
+++ b/tests/TestSuite_vlan_ethertype_config.py
@@ -286,8 +286,12 @@ class TestVlanEthertypeConfig(TestCase):
             self.dut.send_expect("vlan set outer tpid 0x%x %s" %
                                  (tpid, dutTxPortId), "testpmd> ")
             for tx_vlan in tx_vlans:
+                self.dut.send_expect("stop", "testpmd>")
+                self.dut.send_expect("port stop all", "testpmd> ")
                 self.dut.send_expect(
                     "tx_vlan set %s 0x%x" % (dutTxPortId, tx_vlan), "testpmd> ")
+                self.dut.send_expect("port start all", "testpmd> ")
+                self.dut.send_expect("start", "testpmd>")
                 self.start_tcpdump(self.rxItf)
                 self.vlan_send_packet(-1)
                 out = self.get_tcpdump_packet(self.rxItf)
@@ -296,8 +300,12 @@ class TestVlanEthertypeConfig(TestCase):
                 self.verify(str("%x" % tpid) in out, "Wrong vlan:" + str(out))
                 self.verify(
                     str("%x" % tx_vlan) in out, "Vlan not found:" + str(out))
+                self.dut.send_expect("stop", "testpmd>")
+                self.dut.send_expect("port stop all", "testpmd> ")
                 self.dut.send_expect(
                     "tx_vlan reset %s" % dutTxPortId, "testpmd> ", 30)
+                self.dut.send_expect("port start all", "testpmd> ")
+                self.dut.send_expect("start", "testpmd>")
                 self.start_tcpdump(self.rxItf)
                 self.vlan_send_packet(-1)
                 out = self.get_tcpdump_packet(self.rxItf)
-- 
1.9.3

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [dts] [PATCH V1] tests/TestSuite_vlan_ethertype_config.py :stop port before set tx_vlan
  2018-02-08  8:04 [dts] [PATCH V1] tests/TestSuite_vlan_ethertype_config.py :stop port before set tx_vlan zhu,shuai
@ 2018-02-11 10:25 ` Liu, Yong
  0 siblings, 0 replies; 2+ messages in thread
From: Liu, Yong @ 2018-02-11 10:25 UTC (permalink / raw)
  To: zhu,shuai, dts

Thanks, Shuai. Applied.

On 02/08/2018 04:04 PM, zhu,shuai wrote:
> diff --git a/tests/TestSuite_vlan_ethertype_config.py b/tests/TestSuite_vlan_ethertype_config.py
> index 8e6dd49..1fb30fb 100644
> --- a/tests/TestSuite_vlan_ethertype_config.py
> +++ b/tests/TestSuite_vlan_ethertype_config.py
> @@ -286,8 +286,12 @@ class TestVlanEthertypeConfig(TestCase):
>               self.dut.send_expect("vlan set outer tpid 0x%x %s" %
>                                    (tpid, dutTxPortId), "testpmd> ")
>               for tx_vlan in tx_vlans:
> +                self.dut.send_expect("stop", "testpmd>")
> +                self.dut.send_expect("port stop all", "testpmd> ")
>                   self.dut.send_expect(
>                       "tx_vlan set %s 0x%x" % (dutTxPortId, tx_vlan), "testpmd> ")
> +                self.dut.send_expect("port start all", "testpmd> ")
> +                self.dut.send_expect("start", "testpmd>")
>                   self.start_tcpdump(self.rxItf)
>                   self.vlan_send_packet(-1)
>                   out = self.get_tcpdump_packet(self.rxItf)
> @@ -296,8 +300,12 @@ class TestVlanEthertypeConfig(TestCase):
>                   self.verify(str("%x" % tpid) in out, "Wrong vlan:" + str(out))
>                   self.verify(
>                       str("%x" % tx_vlan) in out, "Vlan not found:" + str(out))
> +                self.dut.send_expect("stop", "testpmd>")
> +                self.dut.send_expect("port stop all", "testpmd> ")
>                   self.dut.send_expect(
>                       "tx_vlan reset %s" % dutTxPortId, "testpmd> ", 30)
> +                self.dut.send_expect("port start all", "testpmd> ")
> +                self.dut.send_expect("start", "testpmd>")
>                   self.start_tcpdump(self.rxItf)
>                   self.vlan_send_packet(-1)
>                   out = self.get_tcpdump_packet(self.rxItf)

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-02-11  2:34 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-02-08  8:04 [dts] [PATCH V1] tests/TestSuite_vlan_ethertype_config.py :stop port before set tx_vlan zhu,shuai
2018-02-11 10:25 ` Liu, Yong

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).