Skip to content

chore(ci): run tests on windows #3785

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 3 commits into
base: main
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 36 additions & 0 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,42 @@
env:
NEXTEST_RETRIES: 3

rust-windows:
needs: meta
runs-on: windows-2022
permissions:
contents: read
timeout-minutes: 20
defaults:
run:
shell: bash
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
- name: Install Rust (rustup)
run: rustup update stable --no-self-update && rustup default stable
- name: Install nextest
run: curl -LsSf https://get.nexte.st/latest/windows-tar | tar zxf - -C "$CARGO_HOME"/bin
- name: Add windows target
run: rustup target add x86_64-pc-windows-gnu
- name: Install nasm
run: choco install nasm
- name: Install protoc
run: choco install protoc
- name: Install LLVM and Clang
uses: KyleMayes/install-llvm-action@6ba6e2cd3813def9879be378609d87cb3ef3bac3
with:
version: "19.1.7"
directory: ${{ runner.temp }}/llvm
- name: Set LIBCLANG_PATH
run: echo "LIBCLANG_PATH=$((gcm clang).source -replace "clang.exe")" >> "$GITHUB_ENV"

Check failure on line 133 in .github/workflows/pr.yml

View workflow job for this annotation

GitHub Actions / actions

shellcheck reported issue in this script: SC1072:error:1:28: Fix any mentioned problems and try again ``` run: echo "LIBCLANG_PATH=$((gcm clang).source -replace "clang.exe")" >> "$GITHUB_ENV" ^~~~ ```

Check failure on line 133 in .github/workflows/pr.yml

View workflow job for this annotation

GitHub Actions / actions

shellcheck reported issue in this script: SC1009:info:1:21: The mentioned syntax error was in this $((..)) expression ``` run: echo "LIBCLANG_PATH=$((gcm clang).source -replace "clang.exe")" >> "$GITHUB_ENV" ^~~~ ```

Check failure on line 133 in .github/workflows/pr.yml

View workflow job for this annotation

GitHub Actions / actions

shellcheck reported issue in this script: SC1073:error:1:21: Couldn't parse this $((..)) expression. Fix to allow more checks ``` run: echo "LIBCLANG_PATH=$((gcm clang).source -replace "clang.exe")" >> "$GITHUB_ENV" ^~~~ ```
- run: cargo fetch --locked
- run: cargo fmt -- --check
- run: cargo clippy --target=x86_64-pc-windows-gnu --workspace --all-targets --frozen
- run: cargo nextest run --target=x86_64-pc-windows-gnu --workspace --frozen --exclude=linkerd2-proxy --no-run
- run: cargo nextest run --target=x86_64-pc-windows-gnu --workspace --frozen --exclude=linkerd2-proxy
env:
NEXTEST_RETRIES: 3

rust-crates:
needs: meta
if: needs.meta.outputs.cargo_changed == 'true'
Expand Down
Loading