forked from Conflux-Chain/conflux-rust
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
53 lines (53 loc) · 1.5 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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
branches:
only:
- master
language: rust
matrix:
include:
# unit tests
- env:
- CACHE_NAME=unit_tests
cache:
timeout: 300
cargo: true
install:
- if [ -f target/Cargo.lock ]; then mv target/Cargo.lock .; fi
- export RUSTFLAGS="-D warnings"
- sh cargo_fmt.sh -- --check
- cargo build --release
script:
- cargo test --release --all
before_cache:
- cp Cargo.lock target
# benchmark tests
- env:
- CACHE_NAME=bench
cache:
timeout: 300
cargo: true
install:
- if [ -f target/Cargo.lock ]; then mv target/Cargo.lock .; fi
- export RUSTFLAGS="-g -D warnings"
script:
- cargo bench --all --no-run
before_cache:
- cp Cargo.lock target
# integration tests
- env:
- CACHE_NAME=integration_tests
cache:
timeout: 300
cargo: true
before_install:
# python3.6 is requried for integration tests.
- pyenv install 3.6.2
- pyenv global 3.6.2
- ./dev-support/dep_pip3.sh
install:
- if [ -f target/Cargo.lock ]; then mv target/Cargo.lock .; fi
- export RUSTFLAGS="-g -D warnings"
- cargo build --release
script:
- ./tests/test_all.py
before_cache:
- cp Cargo.lock target