run cfail tests only when rustc --version == $MSRV

this version is more or less fixed so new releases of Rust (stable or nightly
channel) are unlikely to break to build due to changes in diagnostic messages
This commit is contained in:
Jorge Aparicio 2019-11-06 19:39:57 -05:00
parent 31b392fe3a
commit da9c6a714e
2 changed files with 6 additions and 3 deletions

View file

@ -37,8 +37,11 @@ main() {
mkdir -p ci/builds
if [ $T = x86_64-unknown-linux-gnu ]; then
# compile-fail tests
cargo test --test single --target $T
if [ $TRAVIS_RUST_VERSION == 1.*.* ]; then
# test on a fixed version (MSRV) to avoid problems with changes in rustc diagnostics
# compile-fail tests
cargo test --test single --target $T
fi
if [ $TRAVIS_RUST_VERSION = nightly ]; then
# multi-core compile-pass tests

View file

@ -4,7 +4,7 @@ warning: unused import: `rtfm::app`
3 | use rtfm::app;
| ^^^^^^^^^
|
= note: `#[warn(unused_imports)]` on by default
= note: #[warn(unused_imports)] on by default
error[E0080]: evaluation of constant value failed
--> $DIR/task-priority-too-high.rs:5:1