[OE-core] [PATCH 06/13] oeqa/testimage: Added support for folder names in TEST_SUITES.
Costin Constantin
costin.c.constantin at intel.com
Sun Jan 24 19:49:44 UTC 2016
From: Lucian Musat <george.l.musat at intel.com>
You can add oeqa.runtime.<foldername> and it will run all the
tests found in it. Basically extends the functionality of feature
[YOCTO #7834]
Signed-off-by: Lucian Musat <george.l.musat at intel.com>
---
meta/classes/testimage.bbclass | 11 ++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/meta/classes/testimage.bbclass b/meta/classes/testimage.bbclass
index 2e963f8..400d16d 100644
--- a/meta/classes/testimage.bbclass
+++ b/meta/classes/testimage.bbclass
@@ -143,7 +143,16 @@ def get_tests_list(d, type="runtime"):
for testname in testsuites:
if testname != "auto":
if testname.startswith("oeqa."):
- testslist.append(testname)
+ for p in bbpath:
+ test_location = os.path.join(p, 'lib', os.sep.join(testname.split('.')))
+ if os.path.isfile(test_location+".py") or \
+ (os.path.isfile(test_location.rsplit(os.sep, 1)[0]+".py")) or \
+ (os.path.isfile(test_location.rsplit(os.sep, 2)[0]+".py")):
+ testslist.append(testname)
+ elif os.path.isdir(test_location):
+ for files in os.listdir(test_location):
+ if (files.endswith(".py")) and not files.startswith("_"):
+ testslist.append(testname+'.'+files.split('.')[0])
continue
found = False
for p in bbpath:
--
2.5.0
More information about the Openembedded-core
mailing list