aboutsummaryrefslogtreecommitdiffstats
path: root/meta/lib/oeqa/core
diff options
context:
space:
mode:
authorAníbal Limón <anibal.limon@linux.intel.com>2017-05-26 15:37:39 -0500
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-05-30 10:15:22 +0100
commit257d9ef4531052ba8507771b58884c7d2b64143d (patch)
tree8418a6c0b7135d5e2cf12edd32b125442e2cfd31 /meta/lib/oeqa/core
parent3ec0d3825aa31219e0ccabc1f158d3a2f8adbda2 (diff)
downloadopenembedded-core-contrib-257d9ef4531052ba8507771b58884c7d2b64143d.tar.gz
oeqa/core/decorator/depends: Add support for threading mode
The _skipTestDependency needs to know if the thread mode is enabled because the _results are by thread. [YOCTO #11450] Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/lib/oeqa/core')
-rw-r--r--meta/lib/oeqa/core/decorator/depends.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/meta/lib/oeqa/core/decorator/depends.py b/meta/lib/oeqa/core/decorator/depends.py
index 195711cf1e..baa04341c7 100644
--- a/meta/lib/oeqa/core/decorator/depends.py
+++ b/meta/lib/oeqa/core/decorator/depends.py
@@ -3,6 +3,7 @@
from unittest import SkipTest
+from oeqa.core.threaded import OETestRunnerThreaded
from oeqa.core.exception import OEQADependency
from . import OETestDiscover, registerDecorator
@@ -63,7 +64,12 @@ def _order_test_case_by_depends(cases, depends):
return [cases[case_id] for case_id in cases_ordered]
def _skipTestDependency(case, depends):
- results = case.tc._results
+ if isinstance(case.tc.runner, OETestRunnerThreaded):
+ import threading
+ results = case.tc._results[threading.get_ident()]
+ else:
+ results = case.tc._results
+
skipReasons = ['errors', 'failures', 'skipped']
for reason in skipReasons: