+
Failed
+
{% endif %}
- {{ failure.name }} - result: {{ failure.result }}
- {{ failure.stdout }}
+ {% if failure.stdout %}
+ Output: {{ failure.stdout }}
+ {% endif %}
+ {% if failure.image_data is defined %}
+
+ {% endif %}
{% if loop.last %}
@@ -86,6 +196,12 @@ aparser.add_argument('--output', metavar='FILE',
help='The output HTML file, stdout by default',
type=argparse.FileType('w', encoding='UTF-8'),
default=sys.stdout)
+aparser.add_argument('--reftest-suite', metavar='NAME',
+ help='The name of the reftests suite',
+ default='reftest')
+aparser.add_argument('--reftest-output-dir', metavar='DIR',
+ help='The output directory for reftests data',
+ default=None)
aparser.add_argument('infile', metavar='FILE',
help='The input testlog.json, stdin by default',
type=argparse.FileType('r', encoding='UTF-8'),
@@ -111,6 +227,18 @@ for line in args.infile:
'stdout': data['stdout'],
}
+ if args.reftest_output_dir is not None and suite_name == args.reftest_suite:
+ filename = unit_name.split(' ')[1]
+ basename = os.path.splitext(filename)[0]
+
+ image_data = {
+ 'ref': os.path.join(args.reftest_output_dir, '{}.ref.png'.format(basename)),
+ 'out': os.path.join(args.reftest_output_dir, '{}.out.png'.format(basename)),
+ 'diff': os.path.join(args.reftest_output_dir, '{}.diff.png'.format(basename)),
+ }
+
+ unit['image_data'] = image_data
+
units = suites.setdefault(full_suite, [])
units.append(unit)
diff --git a/.gitlab-ci/test-docker.sh b/.gitlab-ci/test-docker.sh
index 45de67000a..05d7c3a45c 100755
--- a/.gitlab-ci/test-docker.sh
+++ b/.gitlab-ci/test-docker.sh
@@ -47,6 +47,7 @@ $srcdir/.gitlab-ci/meson-junit-report.py \
$srcdir/.gitlab-ci/meson-html-report.py \
--project-name=GTK \
--job-id="${CI_JOB_NAME}" \
+ --reftest-output-dir="testsuite/reftests/output" \
--output=report.html \
meson-logs/testlog.json