[dts] [PATCH V1] Add steps to clean environment
Chen, BoX C
box.c.chen at intel.com
Thu May 21 11:36:12 CEST 2020
Tested-by: Chen, BoX C <box.c.chen at intel.com>
Regards,
Chen Bo
> -----Original Message-----
> From: Chen, BoX C <box.c.chen at intel.com>
> Sent: May 21, 2020 17:32
> To: dts at dpdk.org
> Cc: Chen, BoX C <box.c.chen at intel.com>
> Subject: [dts][PATCH V1] Add steps to clean environment
>
> If the test result is failed, the IP set previously will be reserved, need del IP
>
> Signed-off-by: ChenBo <box.c.chen at intel.com>
> ---
> tests/TestSuite_kni.py | 6 +++++-
> 1 file changed, 5 insertions(+), 1 deletion(-)
>
> diff --git a/tests/TestSuite_kni.py b/tests/TestSuite_kni.py index
> 2b2281d..d518f3e 100644
> --- a/tests/TestSuite_kni.py
> +++ b/tests/TestSuite_kni.py
> @@ -1210,7 +1210,11 @@ class TestKni(TestCase):
> """
> Run after each test case.
> """
> - pass
> + if self._suite_result.test_case == "test_ping":
> + for port in self.config['ports']:
> + tx_port = self.tester.get_local_port(port)
> + tx_interface = self.tester.get_interface(tx_port)
> + self.tester.send_expect("ip addr flush %s" %
> + tx_interface, "# ")
>
> def tear_down_all(self):
> """
> --
> 2.17.1
-------------- next part --------------
A non-text attachment was scrubbed...
Name: TestKni.log
Type: application/octet-stream
Size: 70504 bytes
Desc: TestKni.log
URL: <http://mails.dpdk.org/archives/dts/attachments/20200521/ba9a43dd/attachment.obj>
More information about the dts
mailing list