[gtk/report-fixes: 4/4] ci: Use result instead of exit code in the JUnit report
- From: Emmanuele Bassi <ebassi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/report-fixes: 4/4] ci: Use result instead of exit code in the JUnit report
- Date: Thu, 13 Feb 2020 13:59:39 +0000 (UTC)
commit 00db9bd18970e1418d70001bba4e2a4e5f4e018d
Author: Emmanuele Bassi <ebassi gnome org>
Date: Thu Feb 13 13:56:33 2020 +0000
ci: Use result instead of exit code in the JUnit report
We have a result code coming from Meson which is more accurate than just
looking at the exit code of the unit.
.gitlab-ci/meson-junit-report.py | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/.gitlab-ci/meson-junit-report.py b/.gitlab-ci/meson-junit-report.py
index 248ef6e2b1..f63c82eb36 100755
--- a/.gitlab-ci/meson-junit-report.py
+++ b/.gitlab-ci/meson-junit-report.py
@@ -51,6 +51,7 @@ for line in args.infile:
duration = data['duration']
return_code = data['returncode']
+ result = data['result']
log = data['stdout']
unit = {
@@ -58,6 +59,7 @@ for line in args.infile:
'name': unit_name,
'duration': duration,
'returncode': return_code,
+ 'result': result,
'stdout': log,
}
@@ -68,12 +70,12 @@ for name, units in suites.items():
print('Processing suite {} (units: {})'.format(name, len(units)))
def if_failed(unit):
- if unit['returncode'] != 0:
+ if unit['result'] in ['FAIL', 'UNEXPECTEDPASS', 'TIMEOUT']:
return True
return False
def if_succeded(unit):
- if unit['returncode'] == 0:
+ if unit['result'] in ['OK', 'EXPECTEDFAIL', 'SKIP']:
return True
return False
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]