diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2019-05-08 16:20:19 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2019-05-22 00:31:49 +0100 |
commit | 7b1cbc340b066a4aac3cce3161879a02e93f63e2 (patch) | |
tree | efe9fa1c97828550d6c6d524b462daa92113f4ca | |
parent | 2f91565eab78a60569c9f79d8a9cd96c1cc27897 (diff) | |
download | poky-7b1cbc340b066a4aac3cce3161879a02e93f63e2.tar.gz |
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.
(From OE-Core rev: 3c164b94fbb0efc513ee747cccd571a73688b541)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r-- | meta/lib/oeqa/core/runner.py | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/meta/lib/oeqa/core/runner.py b/meta/lib/oeqa/core/runner.py index 478b7b6683..2deba6e932 100644 --- a/meta/lib/oeqa/core/runner.py +++ b/meta/lib/oeqa/core/runner.py | |||
@@ -88,11 +88,17 @@ class OETestResult(_TestResult): | |||
88 | 88 | ||
89 | def _getTestResultDetails(self, case): | 89 | def _getTestResultDetails(self, case): |
90 | result_types = {'failures': 'FAILED', 'errors': 'ERROR', 'skipped': 'SKIPPED', | 90 | result_types = {'failures': 'FAILED', 'errors': 'ERROR', 'skipped': 'SKIPPED', |
91 | 'expectedFailures': 'EXPECTEDFAIL', 'successes': 'PASSED'} | 91 | 'expectedFailures': 'EXPECTEDFAIL', 'successes': 'PASSED', |
92 | 'unexpectedSuccesses' : 'PASSED'} | ||
92 | 93 | ||
93 | for rtype in result_types: | 94 | for rtype in result_types: |
94 | found = False | 95 | found = False |
95 | for (scase, msg) in getattr(self, rtype): | 96 | for resultclass in getattr(self, rtype): |
97 | # unexpectedSuccesses are just lists, not lists of tuples | ||
98 | if isinstance(resultclass, tuple): | ||
99 | scase, msg = resultclass | ||
100 | else: | ||
101 | scase, msg = resultclass, None | ||
96 | if case.id() == scase.id(): | 102 | if case.id() == scase.id(): |
97 | found = True | 103 | found = True |
98 | break | 104 | break |