Skip to content

Commit b67cdf8

Browse files
committed
Update CI to test on windows
1 parent d2824a0 commit b67cdf8

File tree

1 file changed

+23
-6
lines changed

1 file changed

+23
-6
lines changed

.github/workflows/rust.yml

Lines changed: 23 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,19 @@ jobs:
4646
run: |
4747
rustup target add x86_64-unknown-linux-musl
4848
cargo check -p minion -p minion-ffi -p minion-cli --target x86_64-unknown-linux-musl
49+
rustup target add x86_64-pc-windows-gnu
50+
cargo check -p minion -p minion-ffi -p minion-cli --target x86_64-unknown-windows-gnu
4951
tests:
50-
runs-on: ubuntu-latest
52+
strategy:
53+
matrix:
54+
os: ["ubuntu-20.04", "windows-2019"]
55+
include:
56+
- os: "ubuntu-20.04"
57+
target: "x86_64-unknown-linux-musl"
58+
- os: "windows-2019"
59+
target: "x86_64-pc-windows-gnu"
60+
fail-fast: true
61+
runs-on: ${{ matrix.os }}
5162
steps:
5263
- uses: actions/checkout@v2
5364
- uses: actions-rs/toolchain@v1.0.6
@@ -57,13 +68,19 @@ jobs:
5768
- name: Compile tests
5869
run: |
5970
rm -rf .cargo
60-
cd minion-tests
61-
TARGET=x86_64-unknown-linux-musl
62-
rustup target add $TARGET
63-
cargo build -Zunstable-options --out-dir=../out --target=$TARGET
64-
- name: Run tests
71+
cd minion-tests
72+
73+
rustup target add ${{ maxtix.target }}
74+
cargo build -Zunstable-options --out-dir=../out --target=${{ matrix.target }}
75+
- name: Run tests (Linux)
76+
if: matrix.os == "ubuntu-20.04"
77+
timeout-minutes: 3
6578
run: |
6679
sudo ./out/minion-tests --trace
80+
- name: Run tests (Windows)
81+
if: martix.os == "windows-2019"
82+
run: |
83+
./out.minion-tests.exe
6784
timeout-minutes: 3
6885
- name: Collect logs
6986
if: always()

0 commit comments

Comments
 (0)