[dts] [PATCH V1]softnic: restore nic driver after test finished
Xie,WeiX
weix.xie at intel.com
Wed Apr 22 07:38:26 CEST 2020
From: "Xie,WeiX" <weix.xie at intel.com>
*. restore nic drivers after case end to avoid interfere other cases
Signed-off-by: Xie,WeiX <weix.xie at intel.com>
---
tests/TestSuite_softnic.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/tests/TestSuite_softnic.py b/tests/TestSuite_softnic.py
index 9a400fb..c6ba6b9 100644
--- a/tests/TestSuite_softnic.py
+++ b/tests/TestSuite_softnic.py
@@ -55,7 +55,7 @@ class TestSoftnic(TestCase):
# Verify that enough ports are available
self.verify(len(ports) >= 1, "Insufficient ports for testing")
-
+ self.def_driver = self.dut.ports_info[ports[0]]['port'].get_nic_driver()
self.ports_socket = self.dut.get_numa_id(ports[0])
# Verify that enough threads are available
cores = self.dut.get_core_list("1S/1C/1T")
@@ -223,4 +223,4 @@ class TestSoftnic(TestCase):
"""
Run after each test suite.
"""
- pass
+ self.dut.bind_interfaces_linux(driver=self.def_driver, nics_to_bind=self.dut.get_ports())
--
1.8.3.1
More information about the dts
mailing list