test suite reviews and discussions
 help / color / Atom feed
* [dts] [PATCH V1] tests/kernelpf_iavf: destory env need remove to run after this case
@ 2020-07-01  9:30 Xie wei
  2020-07-02  7:17 ` Tu, Lijuan
  0 siblings, 1 reply; 2+ messages in thread
From: Xie wei @ 2020-07-01  9:30 UTC (permalink / raw)
  To: dts; +Cc: Xie wei

If vf_rx_interrupt verified failed, it can't restore env and influence
after cases.

Signed-off-by: Xie wei <weix.xie@intel.com>
---
 tests/TestSuite_kernelpf_iavf.py | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/tests/TestSuite_kernelpf_iavf.py b/tests/TestSuite_kernelpf_iavf.py
index fd48fa2..6fb1bae 100644
--- a/tests/TestSuite_kernelpf_iavf.py
+++ b/tests/TestSuite_kernelpf_iavf.py
@@ -891,9 +891,6 @@ class TestKernelpfIavf(TestCase):
         self.verify('L3FWD_POWER: lcore 6 is waked up from rx interrupt' in out, 'lcore 6 is not waked up')
         self.verify('L3FWD_POWER: lcore 7 is waked up from rx interrupt' in out, 'lcore 7 is not waked up')
         self.dut.send_expect("killall l3fwd-power", "# ", 60, alt_session=True)
-        self.interrupt_flag = True
-        time.sleep(1)
-        self.destroy_2vf_in_2pf()
 
     def test_vf_unicast(self):
         self.vm_testpmd.start_testpmd("all")
@@ -984,8 +981,9 @@ class TestKernelpfIavf(TestCase):
         """
         Run after each test case.
         """
-        if self.interrupt_flag is True:
-            self.interrupt_flag = False
+        if self.running_case == "test_vf_rx_interrupt"::
+            self.dut.send_expect("killall l3fwd-power", "# ", 60, alt_session=True)
+            self.destroy_2vf_in_2pf()
         else:
             self.vm_testpmd.execute_cmd("quit", "#")
             time.sleep(1)
-- 
2.17.1


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

* Re: [dts] [PATCH V1] tests/kernelpf_iavf: destory env need remove to run after this case
  2020-07-01  9:30 [dts] [PATCH V1] tests/kernelpf_iavf: destory env need remove to run after this case Xie wei
@ 2020-07-02  7:17 ` Tu, Lijuan
  0 siblings, 0 replies; 2+ messages in thread
From: Tu, Lijuan @ 2020-07-02  7:17 UTC (permalink / raw)
  To: Xie, WeiX, dts; +Cc: Xie, WeiX

Applied, thanks

> -----Original Message-----
> From: dts <dts-bounces@dpdk.org> On Behalf Of Xie wei
> Sent: 2020^[$BG/^[(B7^[$B7n^[(B1^[$BF|^[(B 17:31
> To: dts@dpdk.org
> Cc: Xie, WeiX <weix.xie@intel.com>
> Subject: [dts] [PATCH V1] tests/kernelpf_iavf: destory env need remove to run
> after this case
> 
> If vf_rx_interrupt verified failed, it can't restore env and influence after cases.
> 
> Signed-off-by: Xie wei <weix.xie@intel.com>
> ---
>  tests/TestSuite_kernelpf_iavf.py | 8 +++-----
>  1 file changed, 3 insertions(+), 5 deletions(-)
> 
> diff --git a/tests/TestSuite_kernelpf_iavf.py b/tests/TestSuite_kernelpf_iavf.py
> index fd48fa2..6fb1bae 100644
> --- a/tests/TestSuite_kernelpf_iavf.py
> +++ b/tests/TestSuite_kernelpf_iavf.py
> @@ -891,9 +891,6 @@ class TestKernelpfIavf(TestCase):
>          self.verify('L3FWD_POWER: lcore 6 is waked up from rx interrupt' in out,
> 'lcore 6 is not waked up')
>          self.verify('L3FWD_POWER: lcore 7 is waked up from rx interrupt' in out,
> 'lcore 7 is not waked up')
>          self.dut.send_expect("killall l3fwd-power", "# ", 60, alt_session=True)
> -        self.interrupt_flag = True
> -        time.sleep(1)
> -        self.destroy_2vf_in_2pf()
> 
>      def test_vf_unicast(self):
>          self.vm_testpmd.start_testpmd("all")
> @@ -984,8 +981,9 @@ class TestKernelpfIavf(TestCase):
>          """
>          Run after each test case.
>          """
> -        if self.interrupt_flag is True:
> -            self.interrupt_flag = False
> +        if self.running_case == "test_vf_rx_interrupt"::
> +            self.dut.send_expect("killall l3fwd-power", "# ", 60, alt_session=True)
> +            self.destroy_2vf_in_2pf()
>          else:
>              self.vm_testpmd.execute_cmd("quit", "#")
>              time.sleep(1)
> --
> 2.17.1


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

end of thread, back to index

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-01  9:30 [dts] [PATCH V1] tests/kernelpf_iavf: destory env need remove to run after this case Xie wei
2020-07-02  7:17 ` Tu, Lijuan

test suite reviews and discussions

Archives are clonable:
	git clone --mirror http://inbox.dpdk.org/dts/0 dts/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 dts dts/ http://inbox.dpdk.org/dts \
		dts@dpdk.org
	public-inbox-index dts


Newsgroup available over NNTP:
	nntp://inbox.dpdk.org/inbox.dpdk.dts


AGPL code for this site: git clone https://public-inbox.org/ public-inbox