Commit a977119 1 parent cbd6849 commit a977119 Copy full SHA for a977119
File tree 2 files changed +60
-0
lines changed
2 files changed +60
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : " cross-tests"
2
+ description : " tests for aarch64 & mips"
3
+
4
+ inputs :
5
+ rust :
6
+ required : true
7
+ package :
8
+ required : true
9
+ target :
10
+ required : true
11
+ features :
12
+ required : true
13
+
14
+ runs :
15
+ using : " composite"
16
+ steps :
17
+ - uses : actions/checkout@v1
18
+ - uses : actions-rs/toolchain@v1
19
+ with :
20
+ profile : minimal
21
+ toolchain : ${{ inputs.rust }}
22
+ target : ${{ inputs.target }}
23
+ override : true
24
+ - name : Install precompiled cross
25
+ run : |
26
+ export URL=$(curl -s https://api.github.com/repos/rust-embedded/cross/releases/latest | jq -r '.assets[] | select(.name | contains("x86_64-unknown-linux-gnu.tar.gz")) | .browser_download_url')
27
+ wget -O /tmp/binaries.tar.gz $URL
28
+ tar -C /tmp -xzf /tmp/binaries.tar.gz
29
+ mv /tmp/cross ~/.cargo/bin
30
+ shell : bash
31
+ - run : cross test --no-default-features --package ${{ inputs.package }} --target ${{ inputs.target }} --features ${{ inputs.features }}
32
+ shell : bash
Original file line number Diff line number Diff line change @@ -3,6 +3,7 @@ name: sha3
3
3
on :
4
4
pull_request :
5
5
paths :
6
+ - " .github/workflows/sha3.yml"
6
7
- " sha3/**"
7
8
- " Cargo.*"
8
9
push :
55
56
- run : cargo test --no-default-features
56
57
- run : cargo test
57
58
- run : cargo test --all-features
59
+
60
+ # Cross-compiled tests
61
+ cross :
62
+ strategy :
63
+ matrix :
64
+ rust :
65
+ - 1.41.0 # MSRV
66
+ - stable
67
+ target :
68
+ - aarch64-unknown-linux-gnu
69
+ - mips-unknown-linux-gnu
70
+ features :
71
+ - default
72
+
73
+ runs-on : ubuntu-latest
74
+ defaults :
75
+ run :
76
+ # Cross mounts only current package, i.e. by default it ignores workspace's Cargo.toml
77
+ working-directory : .
78
+ steps :
79
+ - uses : actions/checkout@v1
80
+ - uses : ./.github/actions/cross-tests
81
+ with :
82
+ rust : ${{ matrix.rust }}
83
+ package : sha3
84
+ target : ${{ matrix.target }}
85
+ features : ${{ matrix.features }}
You can’t perform that action at this time.
0 commit comments