-
Notifications
You must be signed in to change notification settings - Fork 5
/
tests.sh
executable file
·35 lines (27 loc) · 1.29 KB
/
tests.sh
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
#!/usr/bin/env bash
set -e
function run_test() {
echo $1
cargo clippy --examples --features $2 -- -Dwarnings
cargo build --color=always --release --no-default-features \
--features $2 \
--target thumbv7em-none-eabihf
cargo test --color=always --features $2
cargo clean
}
cargo clippy
cargo test --color=always
run_test "Parse comment" parse-comments
run_test "Parse trailing comment" parse-trailing-comment
run_test "Combine comments & trailing comment" parse-trailing-comment,parse-comments
run_test "Parse checksum" parse-checksum
run_test "Parse checksum & trailing comment" parse-trailing-comment,parse-checksum
run_test "Parse checksum & comments & trailing comment" parse-trailing-comment,parse-comments,parse-checksum
run_test "Parse optional-value" optional-value
run_test "Parse string-value" string-value
run_test "Parse parameters" parse-parameters
run_test "Parse parameters & optional-value" parse-parameters,optional-value
run_test "Parse parameters & string-value" parse-parameters,string-value
run_test "Parse expressions" parse-expressions
run_test "Parse expressions & parameters" parse-expressions,parse-parameters
run_test "All features" parse-comments,parse-trailing-comment,parse-checksum,parse-parameters,parse-expressions,optional-value,string-value