Fail test on warnings (#6043)

* fix (ci): hotfix Docker release

* change (ci): fail test on warnings

* change (config): stderr msgs

* Fix the warnings properly

Co-authored-by: Bastian Köcher <git@kchr.de>
This commit is contained in:
Denis Pisarev
2020-05-18 13:28:20 +02:00
committed by GitHub
parent 3048edd6ef
commit 17900b0483
11 changed files with 18 additions and 77 deletions
+2 -11
View File
@@ -193,22 +193,13 @@ test-linux-stable: &test-linux
variables:
# Enable debug assertions since we are running optimized builds for testing
# but still want to have debug assertions.
RUSTFLAGS: -Cdebug-assertions=y
RUSTFLAGS: "-Cdebug-assertions=y -Dwarnings"
except:
variables:
- $DEPLOY_TAG
script:
- WASM_BUILD_NO_COLOR=1 time cargo test --all --release --verbose --locked |&
tee output.log
- WASM_BUILD_NO_COLOR=1 time cargo test --all --release --verbose --locked
- sccache -s
- echo "____Test job successful, checking for warnings____"
- awk '/^warning:/,/^$/ { print }' output.log > ${CI_COMMIT_SHORT_SHA}_warnings.log
- if [ -s ${CI_COMMIT_SHORT_SHA}_warnings.log ]; then
cat ${CI_COMMIT_SHORT_SHA}_warnings.log;
exit 1;
else
echo "___No warnings___";
fi
test-dependency-rules:
stage: test