From cb3b7f760ed2017da33908c8c60db0283bcb3631 Mon Sep 17 00:00:00 2001 From: Lars Bilke <lars.bilke@ufz.de> Date: Wed, 19 Feb 2020 11:26:57 +0100 Subject: [PATCH] [ci] Added win compiler warnings check. --- scripts/ci/jobs/build-win.yml | 2 +- scripts/ci/jobs/checks.yml | 9 +++++++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/scripts/ci/jobs/build-win.yml b/scripts/ci/jobs/build-win.yml index aab1df16656..232daf4adeb 100644 --- a/scripts/ci/jobs/build-win.yml +++ b/scripts/ci/jobs/build-win.yml @@ -17,7 +17,7 @@ build win: -DOGS_BUILD_PROCESSES=GroundwaterFlow ` -DOGS_USE_PYTHON=ON ` -DOGS_CI_TESTRUNNER_REPEAT=1 - - cmake --build . + - cmake --build . | Tee-Object -FilePath make.output - cmake --build . --target tests - cmake --build . --target ctest - cp Testing/**/Test.xml Tests/ctest.xml diff --git a/scripts/ci/jobs/checks.yml b/scripts/ci/jobs/checks.yml index 4462980f676..0861dddda4a 100644 --- a/scripts/ci/jobs/checks.yml +++ b/scripts/ci/jobs/checks.yml @@ -5,9 +5,14 @@ compiler warnings: allow_failure: true dependencies: - build + - build win script: - - cd build - - "if [[ $(cat make.output | grep warning -i) ]]; then echo 'There were compiler warnings:'; cat make.output | grep warning -i; exit 1; fi" + - exit_code=0 + - cd build + - "if [[ $(cat make.output | grep warning -i) ]]; then echo 'There were compiler warnings:'; cat make.output | grep warning -i; exit_code=1; fi" + - cd ../build-win + - "if [[ $(cat make.output | grep ': warning' -i) ]]; then echo 'There were compiler warnings:'; cat make.output | grep ': warning' -i; exit_code=1; fi" + - exit $exit_code ctest results: -- GitLab