test: hard-fail integration tests on missing module wasms - #54
Open
mfw78 wants to merge 2 commits into
Open
Conversation
Replace the two divergent module_wasm_or_skip copies with a single helper in tests/common: a missing wasm skips locally with a loud message and fails the run when CI is set. Unit tests pin both branches through the env-free core.
The CI-only assert left the local default silently green: a run with zero guest wasms built reported 87/87 passing, since a runner captures the skip message of a passing test. Default to the hard failure and gate the skip behind VIDERE_SKIP_MISSING_WASMS, which CI ignores.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Collapses the two verbatim copies of
workspace_path/module_wasm_or_skip(incrates/videre-host/tests/platform.rsandcrates/videre-host/tests/zero_leak.rs) into a single shared helper atcrates/videre-host/tests/common/mod.rs, and makes a missing module wasm a hard test failure instead of a silent skip.Why
A run with zero wasms built previously reported all-green because
module_wasm_or_skipprintedSKIPand returnedNone, letting every e2e assertion inplatform.rsandzero_leak.rspass unexercised. The shared helper now hard-fails by default with arun \just build-modules`message, gates the old skip behaviour behind an explicitVIDERE_SKIP_MISSING_WASMS=1opt-in, and hasCIoverride that opt-in so the gate can never excuse itself.AGENTS.md` documents the new env var. Closes #38.Testing
cargo clippy -p videre-host --all-targets --all-features -- -D warningsclean.cargo test --doc -p videre-host --all-features0 doctests, ok.RUSTDOCFLAGS='-D warnings' cargo doc --no-deps -p videre-hostclean.cargo fmt --all --checkclean.just build-modulesthencargo nextest run -p videre-host --all-features --no-fail-fast89 tests run, 89 passed, 0 skipped (up from 87, the 6 newcommon::testsunit tests covering the hard-fail, opt-in skip, and CI-overrides-opt-in cases).AI Assistance
Implementation by claude-fable-5, red-team by claude-opus-5, PR by claude-sonnet-5.