tests/unit_tests: fix self.__name__ error
Checks
Commit Message
fix tests/unit_tests: self.__name__ is attribute does not exist.
Signed-off-by: Daxue Gao <daxuex.gao@intel.com>
---
tests/TestSuite_unit_tests_cmdline.py | 2 +-
tests/TestSuite_unit_tests_crc.py | 2 +-
tests/TestSuite_unit_tests_cryptodev_func.py | 2 +-
tests/TestSuite_unit_tests_dump.py | 2 +-
tests/TestSuite_unit_tests_eal.py | 2 +-
tests/TestSuite_unit_tests_event_timer.py | 2 +-
tests/TestSuite_unit_tests_kni.py | 2 +-
tests/TestSuite_unit_tests_loopback.py | 2 +-
tests/TestSuite_unit_tests_lpm.py | 2 +-
tests/TestSuite_unit_tests_mbuf.py | 2 +-
tests/TestSuite_unit_tests_mempool.py | 2 +-
tests/TestSuite_unit_tests_pmd_perf.py | 2 +-
tests/TestSuite_unit_tests_power.py | 2 +-
tests/TestSuite_unit_tests_qos.py | 2 +-
tests/TestSuite_unit_tests_ring.py | 2 +-
tests/TestSuite_unit_tests_ringpmd.py | 2 +-
tests/TestSuite_unit_tests_timer.py | 2 +-
17 files changed, 17 insertions(+), 17 deletions(-)
Comments
On Wed, 22 Jun 2022 10:24:02 +0800, Daxue Gao <daxuex.gao@intel.com> wrote:
> fix tests/unit_tests: self.__name__ is attribute does not exist.
>
> Signed-off-by: Daxue Gao <daxuex.gao@intel.com>
Backported to 22.03, thanks
On Wed, 22 Jun 2022 10:24:02 +0800, Daxue Gao <daxuex.gao@intel.com> wrote:
> fix tests/unit_tests: self.__name__ is attribute does not exist.
>
> Signed-off-by: Daxue Gao <daxuex.gao@intel.com>
Applied, thanks
@@ -33,7 +33,7 @@ class TestUnitTestsCmdline(TestCase):
# icc compilation cost long long time.
self.cores = self.dut.get_core_list("all")
self.logger.warning(
- f"Test Suite {self.__name__} is deprecated and will be removed in the next release"
+ f"Test Suite {self.suite_name} is deprecated and will be removed in the next release"
)
def set_up(self):
@@ -31,7 +31,7 @@ class TestUnitTestsCrc(TestCase):
"""
self.cores = self.dut.get_core_list("all")
self.logger.warning(
- f"Test Suite {self.__name__} is deprecated and will be removed in the next release"
+ f"Test Suite {self.suite_name} is deprecated and will be removed in the next release"
)
def set_up(self):
@@ -14,7 +14,7 @@ class UnitTestsCryptodev(TestCase):
self._app_path = self.dut.apps_name["test"]
cc.bind_qat_device(self, "vfio-pci")
self.logger.warning(
- f"Test Suite {self.__name__} is deprecated and will be removed in the next release"
+ f"Test Suite {self.suite_name} is deprecated and will be removed in the next release"
)
def set_up(self):
@@ -40,7 +40,7 @@ class TestUnitTestsDump(TestCase):
self.start_test_time = 60
self.run_cmd_time = 60
self.logger.warning(
- f"Test Suite {self.__name__} is deprecated and will be removed in the next release"
+ f"Test Suite {self.suite_name} is deprecated and will be removed in the next release"
)
def set_up(self):
@@ -39,7 +39,7 @@ class TestUnitTestsEal(TestCase):
app_name = self.dut.apps_name["test"]
self.test_app_cmdline = app_name + eal_params
self.logger.warning(
- f"Test Suite {self.__name__} is deprecated and will be removed in the next release"
+ f"Test Suite {self.suite_name} is deprecated and will be removed in the next release"
)
def set_up(self):
@@ -40,7 +40,7 @@ class TestUnitTestEventTimer(TestCase):
self.dut.bind_eventdev_port(port_to_bind=self.eventdev_timer_device_bus_id)
self.logger.warning(
- f"Test Suite {self.__name__} is deprecated and will be removed in the next release"
+ f"Test Suite {self.suite_name} is deprecated and will be removed in the next release"
)
def set_up(self):
@@ -38,7 +38,7 @@ class TestUnitTestsKni(TestCase):
self.verify("Error" not in out, "Error loading KNI module: " + out)
self.logger.warning(
- f"Test Suite {self.__name__} is deprecated and will be removed in the next release"
+ f"Test Suite {self.suite_name} is deprecated and will be removed in the next release"
)
#
@@ -56,7 +56,7 @@ class TestUnitTestsLoopback(TestCase):
self.dut.send_expect("rm -fr %s" % self.tmp_path, "# ")
self.dut.send_expect("cp app/test/test_pmd_perf.c %s" % self.tmp_path, "# ")
self.logger.warning(
- f"Test Suite {self.__name__} is deprecated and will be removed in the next release"
+ f"Test Suite {self.suite_name} is deprecated and will be removed in the next release"
)
def set_up(self):
@@ -35,7 +35,7 @@ class TestUnitTestsLpmIpv6(TestCase):
"""
self.cores = self.dut.get_core_list("all")
self.logger.warning(
- f"Test Suite {self.__name__} is deprecated and will be removed in the next release"
+ f"Test Suite {self.suite_name} is deprecated and will be removed in the next release"
)
def set_up(self):
@@ -32,7 +32,7 @@ class TestUnitTestsMbuf(TestCase):
"""
self.cores = self.dut.get_core_list("all")
self.logger.warning(
- f"Test Suite {self.__name__} is deprecated and will be removed in the next release"
+ f"Test Suite {self.suite_name} is deprecated and will be removed in the next release"
)
def set_up(self):
@@ -32,7 +32,7 @@ class TestUnitTestsMempool(TestCase):
"""
self.cores = self.dut.get_core_list("all")
self.logger.warning(
- f"Test Suite {self.__name__} is deprecated and will be removed in the next release"
+ f"Test Suite {self.suite_name} is deprecated and will be removed in the next release"
)
def set_up(self):
@@ -45,7 +45,7 @@ class TestUnitTestsPmdPerf(TestCase):
socket_id = self.dut.ports_info[0]["port"].socket
self.cores = self.dut.get_core_list(config="1S/4C/1T", socket=socket_id)
self.logger.warning(
- f"Test Suite {self.__name__} is deprecated and will be removed in the next release"
+ f"Test Suite {self.suite_name} is deprecated and will be removed in the next release"
)
def set_up(self):
@@ -33,7 +33,7 @@ class TestUnitTestsPower(TestCase):
"""
self.cores = self.dut.get_core_list("all")
self.logger.warning(
- f"Test Suite {self.__name__} is deprecated and will be removed in the next release"
+ f"Test Suite {self.suite_name} is deprecated and will be removed in the next release"
)
def set_up(self):
@@ -34,7 +34,7 @@ class TestUnitTestsQos(TestCase):
"""
self.cores = self.dut.get_core_list("all")
self.logger.warning(
- f"Test Suite {self.__name__} is deprecated and will be removed in the next release"
+ f"Test Suite {self.suite_name} is deprecated and will be removed in the next release"
)
def set_up(self):
@@ -32,7 +32,7 @@ class TestUnitTestsRing(TestCase):
"""
self.cores = self.dut.get_core_list("all")
self.logger.warning(
- f"Test Suite {self.__name__} is deprecated and will be removed in the next release"
+ f"Test Suite {self.suite_name} is deprecated and will be removed in the next release"
)
def set_up(self):
@@ -33,7 +33,7 @@ class TestUnitTestsRingPmd(TestCase):
"""
self.cores = self.dut.get_core_list("all")
self.logger.warning(
- f"Test Suite {self.__name__} is deprecated and will be removed in the next release"
+ f"Test Suite {self.suite_name} is deprecated and will be removed in the next release"
)
def set_up(self):
@@ -39,7 +39,7 @@ class TestUnitTestsTimer(TestCase):
if len(self.cores) > 16:
self.this_timeout = self.this_timeout * len(self.cores) / 16
self.logger.warning(
- f"Test Suite {self.__name__} is deprecated and will be removed in the next release"
+ f"Test Suite {self.suite_name} is deprecated and will be removed in the next release"
)
def set_up(self):