forked from near/nearcore
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpipeline.yml
140 lines (123 loc) · 3.93 KB
/
pipeline.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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
steps:
- label: "cargo test"
command: |
source ~/.cargo/env
RUSTFLAGS='-D warnings' cargo test --locked --workspace
timeout: 60
agents:
- "distro=amazonlinux"
branches: "!master"
- label: "cargo test nightly"
command: |
source ~/.cargo/env
RUSTFLAGS='-D warnings' cargo test --workspace --features nightly_protocol,nightly_protocol_features,protocol_feature_evm
timeout: 60
agents:
- "distro=amazonlinux"
branches: "!master"
- label: "sanity checks"
command: |
source ~/.cargo/env
set -ex
rustc --version && cargo --version
if [ -e deny.toml ]; then
cargo-deny --all-features check bans
fi
RUSTFLAGS='-D warnings' cargo check --workspace --all-targets --all-features
RUSTFLAGS='-D warnings' cargo check -p neard
RUSTFLAGS='-D warnings' cargo check -p neard --features nightly_protocol,nightly_protocol_features
# build a sandbox node should succeed
RUSTFLAGS='-D warnings' cargo check -p neard --features sandbox
python3 scripts/state/update_res.py check
python3 scripts/check_nightly.py
timeout: 30
agents:
- "distro=amazonlinux"
branches: "!master"
- label: "nearlib test"
command: |
source ~/.cargo/env
source ~/.nvm/nvm.sh
source ~/.yarn/yarn.sh
rustup default nightly-2020-05-15
rustup target add wasm32-unknown-unknown
scripts/test_nearlib.sh
timeout: 20
agents:
- "distro=amazonlinux"
branches: "!master"
- label: "backward compatible"
command: |
source ~/.cargo/env
cd pytest
pip3 install --user -r requirements.txt
pwd
ls ..
python3 tests/sanity/backward_compatible.py
ls ../target/debug
branches: "!master !beta !stable"
timeout: 30
agents:
- "distro=amazonlinux"
- label: "upgradable"
command: |
source ~/.cargo/env
cd pytest
pip3 install --user -r requirements.txt
python3 tests/sanity/upgradable.py
branches: "!master"
timeout: 30
agents:
- "distro=amazonlinux"
- label: "db migration"
command: |
source ~/.cargo/env
cd pytest
pip3 install --user -r requirements.txt
python3 tests/sanity/db_migration.py
branches: "!master !beta !stable"
timeout: 30
agents:
- "distro=amazonlinux"
- label: "runtime params estimate"
command: |
source ~/.cargo/env
cd runtime/runtime-params-estimator/test-contract
rustup target add wasm32-unknown-unknown
./build.sh
cd ..
RUSTFLAGS='-D warnings' cargo run --release --package neard --bin neard -- --home /tmp/data init --test-seed=alice.near --account-id=test.near --fast
RUSTFLAGS='-D warnings' cargo run --release --package genesis-populate --bin genesis-populate -- --additional-accounts-num=200000 --home /tmp/data
RUSTFLAGS='-D warnings' cargo run --release --package runtime-params-estimator --bin runtime-params-estimator -- --home /tmp/data --accounts-num 20000 --iters 1 --warmup-iters 1 --metric time
branches: "!master !beta !stable"
timeout: 60
agents:
- "distro=amazonlinux"
#- label: "near-sdk-rs tests"
# trigger: "near-sdk-rs"
# branches: "!master"
# Disable rainbow bridge tests as they are temporary broken
# - label: "rainbow-bridge test"
# command: |
# source ~/.cargo/env
# source ~/.nvm/nvm.sh
# git clone https://github.com/near/rainbow-bridge
# cd rainbow-bridge
# source ci/e2e_ci_prepare_env.sh
# source ci/e2e_ci_prepare_log.sh
# LOCAL_CORE_SRC=.. ci/e2e.sh
# timeout: 60
# agents:
# - "queue=default"
# branches: "!master"
# artifact_paths:
# - "rainbow-bridge/logs/**/*.log"
- label: "cargo check nearcore library (without Cargo.lock)"
command: |
source ~/.cargo/env
rm Cargo.lock
cd nearcore
RUSTFLAGS='-D warnings' cargo check
timeout: 30
agents:
- "distro=amazonlinux"