test(tee-cli): split the live cross-repo drift guards into make test-live - #89
Merged
Conversation
…-live`
`make check` ran two network-dependent tests that skipped dynamically
on transport failures — invisible in CI's single step, and one of them
(the registry runtime-code pin check) has been silently skipping in CI
forever because the admission binary is never installed there. Split
them out so the default suite is hermetic and the live guards get
their own attributable CI step.
- `live_test_manifest.py` (new): the enclave manifest-fixture
byte-parity test and the registry runtime-code pin test move here,
sharing a `_fetch_live` helper. Failure taxonomy unchanged — HTTP
4xx/5xx (artifact moved / ref gone) is a real drift signal and fails —
but transport errors (unreachable, timeout, truncated body) now retry
once before skipping, and the skip reason prints in the target's
verbose output.
- The module name deliberately misses `make test`'s `test*.py`
discovery pattern, so `make check` is now offline-deterministic: no
network, no dynamic skips.
- `make test-live` runs `unittest discover -p "live_test_*.py" -b -v`;
CI runs it as its own step after `make check`, so a cross-repo drift
failure is attributable from the step name alone.
Known gap, now visible instead of silent: the runtime-pin test still
skips in CI ("seismic-measurement-admission not in PATH") until CI
installs the admission binary — e.g. a prebuilt artifact, same
pattern as proposed for verify-quote's container image.
The registry runtime-code pin test has skipped in CI forever (`seismic-measurement-admission` is never on the runner's PATH), and both live tests skipped on network flakes — so the live-tests job could go green while verifying nothing. Two changes make its green mean something: - The live suite never skips. It exists only to be run deliberately, and "ran the drift guards" must mean "got verdicts": a missing admission binary fails with a pointer to the enclave repo, and an unreachable artifact fails after one retry instead of skipping. (`make check`'s binary-gated subprocess tests keep their graceful skip — the default suite degrading politely on machines without the binary is a different, correct contract.) - CI's live-tests job installs the binary: `cargo install --git` from the public enclave repo (small crate — alloy-primitives + clap, none of the enclave workspace's TPM deps), with an actions/cache keyed on enclave's seismic-branch HEAD so warm runs skip the build. Building against enclave's moving branch is the point — the guard asks "does enclave HEAD's pin still match seismic main's artifact" — and also why the install stays out of the required `check` job: cross-repo drift must not redden unrelated PRs.
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.
make checkran two network-dependent tests that skipped dynamically on transport failures — invisible in CI's single step, and one of them (the registry runtime-code pin check) has been silently skipping in CI forever because the admission binary is never installed there. Split them out so the default suite is hermetic and the live guards get their own attributable CI step.live_test_manifest.py(new): the enclave manifest-fixture byte-parity test and the registry runtime-code pin test move here, sharing a_fetch_livehelper. Failure taxonomy unchanged — HTTP 4xx/5xx (artifact moved / ref gone) is a real drift signal and fails — but transport errors (unreachable, timeout, truncated body) now retry once before skipping, and the skip reason prints in the target's verbose output.make test'stest*.pydiscovery pattern, somake checkis now offline-deterministic: no network, no dynamic skips.make test-liverunsunittest discover -p "live_test_*.py" -b -v; CI runs it as its own step aftermake check, so a cross-repo drift failure is attributable from the step name alone.Known gap, now visible instead of silent: the runtime-pin test still skips in CI ("seismic-measurement-admission not in PATH") until CI installs the admission binary — e.g. a prebuilt artifact, same pattern as proposed for verify-quote's container image.