CI: clippy and tests on pull requests and main
A Windows job on the pinned toolchain: clippy with -D warnings on the default and the --all-features (diagnostics) build, then cargo test --workspace, which includes the asset-policy test. main did not build its tests: scalar_bit_tests_lower called lowers() without the rsrc2 argument a parallel change added (0, no input registers). Also drops a double parenthesis clippy flagged in an xasync test. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
1 parent
c7a5f4953f
commit
8e79c80e4b
3 files changed
+35
-2
No files matched your search
@@ -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
|
||||||
@@ -1179,7 +1179,7 @@ mod tests {
|
|||||||
S_OK
|
S_OK
|
||||||
);
|
);
|
||||||
assert_eq!((value, used), (0x1234, 8));
|
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);
|
XTaskQueueCloseHandle(q);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -6960,7 +6960,7 @@ mod tests {
|
|||||||
];
|
];
|
||||||
for head in bit_tests {
|
for head in bit_tests {
|
||||||
let words: Vec<u32> = head.iter().chain(&tail).copied().collect();
|
let words: Vec<u32> = head.iter().chain(&tail).copied().collect();
|
||||||
lowers(&words).unwrap();
|
lowers(&words, 0).unwrap();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user