Try again

This commit is contained in:
Calixte Denizet
2019-02-16 15:28:43 +01:00
parent 90184bcb90
commit 1e3c2fbf18
2 changed files with 24 additions and 10 deletions

View File

@@ -32,6 +32,7 @@ matrix:
env:
- TRAVIS_RUST_VERSION=stable
- REGULAR_TEST=false
- CODE_COVERAGE=false
script: tests/.travis-runner.sh
- language: python
python: 3.6
@@ -45,6 +46,7 @@ matrix:
env:
- TRAVIS_RUST_VERSION=beta
- REGULAR_TEST=false
- CODE_COVERAGE=false
script: tests/.travis-runner.sh
- name: rustfmt
language: rust
@@ -107,20 +109,12 @@ matrix:
directories:
- /home/travis/.cargo
- target
before_script:
- curl -L https://github.com/mozilla/grcov/releases/download/v0.4.1/grcov-linux-x86_64.tar.bz2 | tar jxf -
script:
- cargo build --verbose --all
- cargo test --verbose --all
- tests/.travis-runner.sh
- zip -0 ccov.zip `find . \( -name "rustpython*.gc*" \) -print`
- ./grcov ccov.zip -s . -t lcov --llvm --branch --ignore-not-existing --ignore-dir "/*" > lcov.info
- bash <(curl -s https://codecov.io/bash) -f lcov.info
env:
- TRAVIS_RUST_VERSION=nightly
- REGULAR_TEST=false
- CARGO_INCREMENTAL=0
- RUSTFLAGS="-Zprofile -Ccodegen-units=1 -Cinline-threshold=0 -Clink-dead-code -Coverflow-checks=off -Zno-landing-pads"
- CODE_COVERAGE=true
allow_failures:
- rust: nightly
env: REGULAR_TEST=true

View File

@@ -10,7 +10,27 @@ pip install pipenv
(cd tests; pipenv install)
# Build outside of the test runner
cargo build --verbose --release
if [ $CODE_COVERAGE = "true" ]
then
export CARGO_INCREMENTAL=0
export RUSTFLAGS="-Zprofile -Ccodegen-units=1 -Cinline-threshold=0 -Clink-dead-code -Coverflow-checks=off -Zno-landing-pads"
cargo build --verbose
else
cargo build --verbose --release
fi
# Run the tests
(cd tests; pipenv run pytest)
if [ $CODE_COVERAGE = "true" ]
then
cargo test --verbose --all
zip -0 ccov.zip `find . \( -name "rustpython*.gc*" \) -print`
# Install grcov
curl -L https://github.com/mozilla/grcov/releases/download/v0.4.1/grcov-linux-x86_64.tar.bz2 | tar jxf -
./grcov ccov.zip -s . -t lcov --llvm --branch --ignore-not-existing --ignore-dir "/*" > lcov.info
bash <(curl -s https://codecov.io/bash) -f lcov.info
fi