Browse Source

Add xml results to GitLab so that they are displayed in the GUI

Changelog: None

Signed-off-by: Lluis Campos <lluis.campos@northern.tech>
2.0.x
Lluis Campos 5 years ago
parent
commit
7f35e907f2
  1. 2
      .gitlab-ci.yml
  2. 7
      scripts/run-tests.sh

2
.gitlab-ci.yml

@ -55,3 +55,5 @@ test_acceptance:
paths:
- results_*.xml
- report_*.html
reports:
junit: results_*.xml

7
scripts/run-tests.sh

@ -99,6 +99,10 @@ convert_and_test() {
cd ${WORKSPACE}/mender-image-tests
# This is a trick to make pytest generate different junit reports
# for different runs: renaming the tests folder to tests_<testsuite>
cp -r tests tests_${device_type}
python3 -m pytest --verbose \
--junit-xml="${MENDER_CONVERT_DIR}/results_${device_type}.xml" \
${html_report_args} \
@ -106,7 +110,8 @@ convert_and_test() {
--test-variables="${MENDER_CONVERT_DIR}/deploy/${device_type}-${artifact_name}.cfg" \
--board-type="${device_type}" \
--mender-image=${device_type}-${artifact_name}.sdimg \
--sdimg-location="${MENDER_CONVERT_DIR}/deploy"
--sdimg-location="${MENDER_CONVERT_DIR}/deploy" \
tests_${device_type}
exitcode=$?
cd -

Loading…
Cancel
Save