Files
noq/.github/workflows/wine.yaml
Floris Bruynooghe 4f5b094f98 chore(ci): fix workflows for test binaries locations (#896)
## Description

Rust 1.100 moved around where test binaries are. Update the workflows
so that we're not dependent on this.

## API Changes

n/a

## Notes & open questions

none

## Change checklist

- [x] Self-review.
- [x] Documentation updates following the [style
guide](https://rust-lang.github.io/rfcs/1574-more-api-documentation-conventions.html#appendix-a-full-conventions-text),
if relevant.
- [x] Tests if relevant.
- [x] All API changes documented.
- [x] `cargo make` passes locally.
2026-11-17 07:44:45 +00:00

63 lines
2.1 KiB
YAML

name: Wine Tests
on:
push:
branches: [main]
pull_request:
merge_group:
workflow_dispatch:
concurrency:
group: wine-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
env:
CARGO_TERM_COLOR: always
RUST_BACKTRACE: 1
RUSTFLAGS: -Dwarnings
CARGO_TARGET_X86_64_PC_WINDOWS_GNU_RUNNER: wine
# Default to read-only; jobs that need more grant it explicitly.
permissions:
contents: read
jobs:
wine_test:
name: Wine Sanity Check
runs-on: blacksmith-8vcpu-ubuntu-2404
steps:
- uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4.4.0
with:
persist-credentials: false
- name: Install Wine
run: |
# Use WineHQ for newer Wine with bcryptprimitives.dll support
sudo dpkg --add-architecture i386
sudo mkdir -pm755 /etc/apt/keyrings
sudo wget -O /etc/apt/keyrings/winehq-archive.key https://dl.winehq.org/wine-builds/winehq.key
sudo wget -NP /etc/apt/sources.list.d/ https://dl.winehq.org/wine-builds/ubuntu/dists/$(lsb_release -cs)/winehq-$(lsb_release -cs).sources
sudo apt-get update
sudo apt-get install -y --install-recommends winehq-stable || sudo apt-get install -y wine64 wine32
# Initialize Wine prefix
WINEARCH=win64 wineboot --init
- name: Install Rust + mingw target
uses: dtolnay/rust-toolchain@6c977a6ca4077a0ceb28ffbe03f59d46e9ac8772 # v1
with:
toolchain: stable
targets: x86_64-pc-windows-gnu
- name: Install mingw-w64
run: sudo apt-get install -y mingw-w64
- name: Build tests
# Release mode required - debug builds exceed mingw's export ordinal limit (~65k symbols)
run: cargo test --locked --target x86_64-pc-windows-gnu --tests --release --no-run
- name: List available tests
run: cargo test --locked --target x86_64-pc-windows-gnu --tests --release -- --list
- name: Run tests under Wine
run: cargo test --locked --target x86_64-pc-windows-gnu --tests --release -- --test-threads=1