[dts] [PATCH] tests/TestSuite_multiple_pthread.py: Updated test_positive() and teardown() functions.

Ma, LihongX lihongx.ma at intel.com
Tue Sep 29 07:07:35 CEST 2020


> -----Original Message-----
> From: dts <dts-bounces at dpdk.org> On Behalf Of usurekha at marvell.com
> Sent: Friday, September 25, 2020 5:47 PM
> To: dts at dpdk.org
> Cc: pvukkisala at marvell.com; zzhou at marvell.com; usurekha
> <usurekha at marvell.com>
> Subject: [dts] [PATCH] tests/TestSuite_multiple_pthread.py: Updated
> test_positive() and teardown() functions.
> 
> From: usurekha <usurekha at marvell.com>
> 
> Added script to get the available max cpu depends on DUT config.
> Did modifications in teardown() to close the tester scapy sessions properly.
> 
> Signed-off-by: usurekha <usurekha at marvell.com>
> ---
>  tests/TestSuite_multiple_pthread.py | 18 ++++++++++++------
>  1 file changed, 12 insertions(+), 6 deletions(-)
> 
> diff --git a/tests/TestSuite_multiple_pthread.py
> b/tests/TestSuite_multiple_pthread.py
> index 5d4a1f6..2af8196 100644
> --- a/tests/TestSuite_multiple_pthread.py
> +++ b/tests/TestSuite_multiple_pthread.py
> @@ -62,7 +62,7 @@ class TestMultiplePthread(TestCase):
>          """
>          Run before each test case.
>          """
> -        self.send_sessions = []
> +        self.send_sessions = None
> 

If there are multiple ports on dut, it will create multiple session to send the pkg,
So it should create a list to store all the session info on the suite, otherwise maybe some sessions will lost control.


Regards,
Ma,lihong


More information about the dts mailing list