summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2019-05-08 16:20:19 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2019-05-09 11:58:04 +0100
commit7885939ca3dea9704185e93469fe515c17eb8017 (patch)
tree407d3a595629d6cacc29c99347406191422fb39f /meta
parentf8c9c511b5f1b7dbd45b77f345cb6c048ae6763e (diff)
downloadopenembedded-core-contrib-7885939ca3dea9704185e93469fe515c17eb8017.tar.gz
openembedded-core-contrib-7885939ca3dea9704185e93469fe515c17eb8017.tar.bz2
openembedded-core-contrib-7885939ca3dea9704185e93469fe515c17eb8017.zip
oeqa/core/runner: Handle unexpectedSucesses
Instead of showing: RESULTS - ptest.PtestRunnerTest.test_ptestrunner - Testcase 1600: UNKNOWN (32.30s) map unexpectedSuccesses to PASSED and improve the way they're displayed. We expect/allow ptest runner to fail but if it passes we should handle it correctly. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r--meta/lib/oeqa/core/runner.py10
1 files changed, 8 insertions, 2 deletions
diff --git a/meta/lib/oeqa/core/runner.py b/meta/lib/oeqa/core/runner.py
index 5f708730ed..ca61de8cc0 100644
--- a/meta/lib/oeqa/core/runner.py
+++ b/meta/lib/oeqa/core/runner.py
@@ -91,11 +91,17 @@ class OETestResult(_TestResult):
def _getTestResultDetails(self, case):
result_types = {'failures': 'FAILED', 'errors': 'ERROR', 'skipped': 'SKIPPED',
- 'expectedFailures': 'EXPECTEDFAIL', 'successes': 'PASSED'}
+ 'expectedFailures': 'EXPECTEDFAIL', 'successes': 'PASSED',
+ 'unexpectedSuccesses' : 'PASSED'}
for rtype in result_types:
found = False
- for (scase, msg) in getattr(self, rtype):
+ for resultclass in getattr(self, rtype):
+ # unexpectedSuccesses are just lists, not lists of tuples
+ if isinstance(resultclass, tuple):
+ scase, msg = resultclass
+ else:
+ scase, msg = resultclass, None
if case.id() == scase.id():
found = True
break