pre-push 614 B

123456789101112131415161718
  1. #!/usr/bin/env bash
  2. set -e
  3. SCRIPT_PATH="$(dirname "${BASH_SOURCE[0]}")"
  4. cd $SCRIPT_PATH
  5. source ../../scripts/features.sh
  6. export WASM_BUILD_TOOLCHAIN=nightly-2021-02-20
  7. echo 'running clippy (rust linter)'
  8. # When custom build.rs triggers wasm-build-runner-impl to build we get error:
  9. # "Rust WASM toolchain not installed, please install it!"
  10. # So we skip building the WASM binary by setting BUILD_DUMMY_WASM_BINARY=1
  11. BUILD_DUMMY_WASM_BINARY=1 cargo +nightly-2021-02-20 clippy --release --all -- -D warnings
  12. echo 'running cargo unit tests'
  13. cargo +nightly-2021-02-20 test --release --all --features "${FEATURES}"