clap/.travis.yml
2020-01-31 12:11:25 +01:00

64 lines
1.7 KiB
YAML

os: linux
language: rust
cache: cargo
rust: stable
env:
global:
- SHARD=test
jobs:
allow_failures:
- rust: nightly
- env:
- SHARD=lint
fast_finish: true
include:
- os: osx
- rust: 1.33
- rust: beta
- rust: nightly
- env:
- SHARD=lint
before_script:
- rustup component add clippy
- rustup component add rustfmt
script:
- echo "Checking codebase with Clippy release `cargo clippy --version`."
- cargo clippy --all --all-targets --all-features -- -D warnings
- cargo fmt -- --check
- env:
- SHARD=bench
script:
- cargo bench
script:
- cargo test --all --no-default-features
- cargo test --all --features yaml unstable
addons:
apt:
packages:
- libcurl4-openssl-dev
- libelf-dev
- libdw-dev
- cmake
- gcc
- binutils-dev
update: true
after_success:
- |
wget https://github.com/SimonKagstrom/kcov/archive/master.tar.gz &&
tar xzf master.tar.gz &&
cd kcov-master &&
mkdir build &&
cd build &&
cmake .. &&
make &&
sudo make install &&
cd ../.. &&
rm -rf kcov-master &&
cargo clean &&
cargo test --no-run --features "yaml unstable" &&
for file in target/debug/*-*; do mkdir -p "target/cov/$(basename $file)"; kcov --exclude-pattern=/.cargo --verify "target/cov/$(basename $file)" "$file"; done &&
kcov --coveralls-id=$TRAVIS_JOB_ID --merge target/cov target/cov/* &&
echo "Uploaded code coverage"
env:
global:
- secure: JLBlgHY6OEmhJ8woewNJHmuBokTNUv7/WvLkJGV8xk0t6bXBwSU0jNloXwlH7FiQTc4TccX0PumPDD4MrMgxIAVFPmmmlQOCmdpYP4tqZJ8xo189E5zk8lKF5OyaVYCs5SMmFC3cxCsKjfwGIexNu3ck5Uhwe9jI0tqgkgM3URA=