Skip to content

test: measure that an accepted mount compiles to a flag podman runs - #124

Merged
lesnik512 merged 1 commit into
mainfrom
test/acceptance-oracle
Sep 20, 2026
Merged

lesnik512 merged 1 commit into
mainfrom
test/acceptance-oracle

Conversation

@lesnik512

Copy link
Copy Markdown
Member

Closes #118. Stacked on #123 — GitHub will retarget this to main once that merges. Review #123 first.

The gap

refusals.py measures one direction: podman will not make a mount we refuse. The direction that actually shipped bugs twice — the gate accepts, emit renders, podman run dies — had no oracle at all.

Of the nested option keys that reach a --mount, exactly one was ever executed against real podman, and only one of its six legal values:

key renders as executed before this PR
bind.propagation bind-propagation= rprivate only
bind.selinux relabel= no
tmpfs.size tmpfs-size= no
tmpfs.mode tmpfs-mode= no

subpath sat in that same column for two releases: accepted, emitted, 100% covered by unit tests, and unrunnable on the podman in this repo's own CI.

Result: nothing is broken

All 14 rows exit 0 on podman 4.9.3, including shared/rshared, which I half-expected to fail on a bind whose source is not itself a shared mount. That is the honest outcome and it is still worth having: the point is somewhere for it to go red.

The one design decision

Each row pins expected_argv to what emit actually produces, checked before the flag is run.

That is deliberately the opposite of refusals.py's rule, where the argv is hand-written precisely so an emit bug cannot hide behind a parity claim. Here the emitted flag is the thing under test, so a hand-written argv would measure a flag nobody ships — which is the failure mode this whole issue is about. refusals.py gained a sentence pointing at the new module so the two rules are not read as an inconsistency.

I checked every expected string by eye against emit's output rather than pasting what emit gave me, since a row generated from emit would assert only that emit equals itself.

Verification

Base automatically changed from fix/nocopy-and-reservation-evidence to main September 20, 2026 12:28
`refusals.py` only ever measured that podman refuses what we refuse. The
direction #104 and #114 actually failed in -- the gate accepts, emit
renders, `podman run` dies -- had no oracle at all. Of the nested options
that reach a `--mount`, exactly one (bind propagation, one value of six)
was ever executed.

Each row pins its flag to what `emit` produces before running it, so a row
cannot drift into measuring a flag the tool does not ship.

Closes #118
@lesnik512
lesnik512 force-pushed the test/acceptance-oracle branch from 218f0ff to e8e571a Compare September 20, 2026 12:28
@lesnik512
lesnik512 merged commit e0de766 into main Sep 20, 2026
10 checks passed
@lesnik512
lesnik512 deleted the test/acceptance-oracle branch September 20, 2026 12:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Nothing measures that an accepted form runs: the oracle only covers refusals

1 participant