[OE-core] [PATCH v3 15/52] oetest: Add tearDownLocal class

Joshua Lock joshua.lock at collabora.co.uk
Thu Oct 22 15:21:36 UTC 2015


From: Mariano Lopez <mariano.lopez at linux.intel.com>

In the current state there are some runtime test that
don't run the tearDown method fromm oeRuntimeTest class
because the tearDown class is overwritten in the child
class.

This change adds tearDownLocal method in oeRuntimeTest
class that will run after tearDown. This method can be
overwritten in the child classes to implement specific
test functionality.

[YOCTO #8465]

Signed-off-by: Mariano Lopez <mariano.lopez at linux.intel.com>
Signed-off-by: Ross Burton <ross.burton at intel.com>
---
 meta/lib/oeqa/oetest.py | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/meta/lib/oeqa/oetest.py b/meta/lib/oeqa/oetest.py
index e3bbc46..6f9edec 100644
--- a/meta/lib/oeqa/oetest.py
+++ b/meta/lib/oeqa/oetest.py
@@ -196,6 +196,12 @@ class oeRuntimeTest(oeTest):
             print ("%s dump data stored in %s" % (self._testMethodName,
                      self.tc.host_dumper.dump_dir))
 
+        self.tearDownLocal()
+
+    # Method to be run after tearDown and implemented by child classes
+    def tearDownLocal(self):
+        pass
+
     #TODO: use package_manager.py to install packages on any type of image
     def install_packages(self, packagelist):
         for package in packagelist:
-- 
2.1.4




More information about the Openembedded-core mailing list