tests: name the host GPU adapter and make skipped shader tests explicit #43

Merged
LouisRiverstone merged 1 commit from upstream-pr/43 into main 2026-11-25 20:33:16 +00:00
LouisRiverstone commented 2026-11-25 20:16:37 +00:00 (Migrated from github.com)

Imported from uiliannn/VItoriaBr. Originally posted by LouisRiverstone on 2026-11-25T20:16:37Z.


Closes #32

Why

Host GPU tests passed without saying which adapter ran them (card or WARP), and tests missing a compiler or device returned early, so the harness reported ok for runs that checked nothing.

What changed

  • emit::host::Host gets an adapter field (name (vendor 0x....)) and logs VICTORY HOST GPU: ... once per adapter per process.
  • New test-only emit::test_skip::skip(reason): prints VICTORY TEST SKIPPED: <reason> for every skip. With VICTORY_STRICT_TESTS=1 it panics instead, for machines where the compilers and devices are expected.
  • Every eprintln!("... skipped") / "... not run" site in the shader emit tests (diff, valu, intersect, waterfall, wave64, rect, mod, shader) goes through it, as do the previously silent Host::new fallbacks.

Behavior without VICTORY_STRICT_TESTS is unchanged: same early returns, louder output.

Strict mode fails on any skip, including a missing hardware adapter in the tests that also try WARP, so use it only where a card is present.

Verify

  • cargo clippy -p victory-shader --tests --target x86_64-pc-windows-msvc is clean.
  • I built for the Windows target only (the tests are cfg(windows)) and did not run them. Please run cargo test -p victory-shader on Windows, with and without VICTORY_STRICT_TESTS=1.

🤖 Generated with Claude Code

<!-- greyfinch-sync:uiliannn/VItoriaBr:issue:6612912769 --> Imported from [uiliannn/VItoriaBr](https://github.com/uiliannn/VItoriaBr/pull/43). Originally posted by [LouisRiverstone](https://github.com/LouisRiverstone) on 2026-11-25T20:16:37Z. --- Closes #32 ## Why Host GPU tests passed without saying which adapter ran them (card or WARP), and tests missing a compiler or device returned early, so the harness reported `ok` for runs that checked nothing. ## What changed - `emit::host::Host` gets an `adapter` field (`name (vendor 0x....)`) and logs `VICTORY HOST GPU: ...` once per adapter per process. - New test-only `emit::test_skip::skip(reason)`: prints `VICTORY TEST SKIPPED: <reason>` for every skip. With `VICTORY_STRICT_TESTS=1` it panics instead, for machines where the compilers and devices are expected. - Every `eprintln!("... skipped")` / `"... not run"` site in the shader emit tests (diff, valu, intersect, waterfall, wave64, rect, mod, shader) goes through it, as do the previously silent `Host::new` fallbacks. Behavior without `VICTORY_STRICT_TESTS` is unchanged: same early returns, louder output. Strict mode fails on any skip, including a missing hardware adapter in the tests that also try WARP, so use it only where a card is present. ## Verify - `cargo clippy -p victory-shader --tests --target x86_64-pc-windows-msvc` is clean. - I built for the Windows target only (the tests are `cfg(windows)`) and did not run them. Please run `cargo test -p victory-shader` on Windows, with and without `VICTORY_STRICT_TESTS=1`. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
uiliannn/VItoriaBr!43
No description provided.