forked from Joystream/joystream
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
35 lines (29 loc) · 1.43 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
language: rust
# Caching of the runtime .wasm blob poses a problem.
# See: https://github.com/Joystream/joystream/issues/466
# Always starting with a clean slate is probably better, it allows us to ensure
# the WASM runtime is always rebuilt. It also allows us to detect when certain upstream dependencies
# sometimes break the build. When cache is enabled do not use the produced WASM build.
# This also means the binary should not be used to produce the final chainspec file (because the same
# one is embedded in the binary)
cache: cargo
rust:
- stable
matrix:
include:
- os: linux
env: TARGET=x86_64-unknown-linux-gnu
install:
- rustup install nightly-2020-05-23
- rustup target add wasm32-unknown-unknown --toolchain nightly-2020-05-23
# travis installs rust using rustup with the "minimal" profile so these tools are not installed by default
- rustup component add rustfmt
- rustup component add clippy
before_script:
- cargo fmt --all -- --check
script:
# we set release as build type for all steps to benefit from already compiled packages in prior steps
- BUILD_DUMMY_WASM_BINARY=1 cargo clippy --release --target=${TARGET} -- -D warnings
- BUILD_DUMMY_WASM_BINARY=1 cargo test --release --verbose --all --target=${TARGET}
- TRIGGER_WASM_BUILD=1 WASM_BUILD_TOOLCHAIN=nightly-2020-05-23 cargo build --release --target=${TARGET} -p joystream-node
- ls -l ./target/${TARGET}/release/wbuild/joystream-node-runtime/