Factored out CI execution into `ci.sh`.

This commit is contained in:
Marc Brinkmann 2018-10-16 10:17:21 +02:00 committed by Andreas Fackler
parent 6df72d86cc
commit df1471f86d
2 changed files with 20 additions and 13 deletions

View File

@ -20,16 +20,4 @@ before_install:
# # causing a CI slowdown, so this option is commented out by default. It can
# # be enabled per-branch to debug issues.
# - sudo tail -n 250 /var/log/syslog
env:
global:
- RUST_BACKTRACE=1
# Enables additional cpu-specific optimizations.
- RUSTFLAGS="-D warnings -C target-cpu=native"
- MLOCK_SECRETS=false
script:
- cargo clippy --all-targets -- --deny clippy
- cargo clippy --all-features --all-targets -- --deny clippy
- cargo fmt -- --check
- cargo test --features=use-insecure-test-only-mock-crypto --release
- cargo doc
- cargo deadlinks --dir target/doc/hbbft/
script: ./ci.sh

19
ci.sh Executable file
View File

@ -0,0 +1,19 @@
#!/bin/sh
set -xe
export RUST_BACKTRACE=1
# Enables additional cpu-specific optimizations.
export RUSTFLAGS="-D warnings -C target-cpu=native"
# Currently, mlocking secrets is disabled due to secure memory limit issues.
export MLOCK_SECRETS=false
cargo clippy --all-targets -- --deny clippy
cargo clippy --all-features --all-targets -- --deny clippy
cargo fmt -- --check
# We only test with mocktography, to ensure tests aren't unreasonably long.
cargo test --features=use-insecure-test-only-mock-crypto --release
cargo doc
cargo deadlinks --dir target/doc/hbbft/