Tests: hardware tests can no longer pass without running, strict runs fail fast (port of spk-c 7cd474e3) #1334
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/fxceless--victory-fork!1334
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/1334/head"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@CwWwWwW on GitHub · 2026-11-26 15:54 UTC · original
CwWwWwW:port/gpu-test-strict-skip→main· +48 −20 · 1 files · 1 commits · closed without mergingProblem
The wave64 hardware tests in
crates/victory-shader/src/emit/wave64_tests.rsuseHost::new(false)and skip witheprintln!(...); return;when no SM 6.6 device exists. A test that returns counts as a pass, so a CI or developer run requesting hardware coverage reports green while executing nothing - a silently untested shader change can look verified.Found while comparing the other forks: spk-c/victory-fork commit
7cd474e3(spk). It is not in this fork,upstream/main, the #653 batch or any open PR; this is that fix ported unchanged.Change
gpu_unavailable(stage, error): printsGPU test skipped at <stage>: <error>, or panics withGPU test unavailable at <stage>: <error>whenVICTORY_REQUIRE_GPU_TESTS=1.on_the_cardhelper) go through it; the old bareeprintln!skips are gone.Tests
cargo test -p victory-shader --lib wave64(no device here): 8 tests pass (2 pure + 6 hardware skips), as before.VICTORY_REQUIRE_GPU_TESTS=1 cargo test -p victory-shader --lib wave64: 6 hardware tests fail withGPU test unavailable at device initialization: 指定的设备接口或功能级别在此系统上不受支持。, which is the intended strict behavior - a green run can no longer mean "nothing ran".cargo clippy -p victory-shader --all-targets --locked -- -D warnings: clean.(CI note: the
checkjob on main is currently red on the asset-policy violation; #1322 fixes that, after which this can be rebased.)Pull request closed