diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..80e6a35 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,33 @@ +name: CI + +on: + pull_request: + push: + branches: [main] + +permissions: + contents: read + +concurrency: + group: ci-${{ github.ref }} + cancel-in-progress: true + +env: + CARGO_TERM_COLOR: always + +jobs: + check: + runs-on: windows-latest + timeout-minutes: 60 + steps: + - uses: actions/checkout@v5 + # The version and components pinned in rust-toolchain.toml. + - run: rustup toolchain install + - uses: Swatinem/rust-cache@v2 + - name: Clippy + run: cargo clippy --workspace --all-targets --locked -- -D warnings + - name: Clippy, diagnostics build + run: cargo clippy --workspace --all-targets --all-features --locked -- -D warnings + # Includes xtask's repository_passes_policy, the asset-policy check. + - name: Tests + run: cargo test --workspace --locked diff --git a/crates/victory-hle/src/modules/xasync.rs b/crates/victory-hle/src/modules/xasync.rs index 08234ac..068d75f 100644 --- a/crates/victory-hle/src/modules/xasync.rs +++ b/crates/victory-hle/src/modules/xasync.rs @@ -1179,7 +1179,7 @@ mod tests { S_OK ); assert_eq!((value, used), (0x1234, 8)); - assert!(call((&raw mut block)).is_none(), "the call ends with its result"); + assert!(call(&raw mut block).is_none(), "the call ends with its result"); XTaskQueueCloseHandle(q); } diff --git a/crates/victory-shader/src/emit/lower.rs b/crates/victory-shader/src/emit/lower.rs index 7b933c1..211da17 100644 --- a/crates/victory-shader/src/emit/lower.rs +++ b/crates/victory-shader/src/emit/lower.rs @@ -6960,7 +6960,7 @@ mod tests { ]; for head in bit_tests { let words: Vec = head.iter().chain(&tail).copied().collect(); - lowers(&words).unwrap(); + lowers(&words, 0).unwrap(); } }