diff --git a/.travis.yml b/.travis.yml index 1c3bed4..f7efc2e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -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 diff --git a/ci.sh b/ci.sh new file mode 100755 index 0000000..90888ff --- /dev/null +++ b/ci.sh @@ -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/