Skip to content

smoke gate: no floor on executed-assertion count — a near-empty run reads PASSED #219

Description

@unforced

Follow-up nit from the #218 review (non-blocking; #218 is correct as shipped).

summarize() in scripts/smoke-report.ts sets exitCode from fail alone, with no floor on pass:

summarize({pass: 0, fail: 0, advisory: 7})
-> exit 0 | SMOKE PASSED — 0 pass, 0 fail, 7 advisory (UNVERIFIED — see below)

That is correct per invariant 1 (advisories never gate) and the state is currently unreachable: login is outside any liveCatch range and runs first, so a dead staging throws and main().catch() exits 1 before reaching a wrapped section.

The point is that the safety is emergent, not pinned. It holds because of where login happens to sit in the file, and nothing fails if a future change wraps an early section or moves login. A floor makes it explicit:

  • assert a minimum executed-assertion count (or pass > 0) before allowing exit 0, and
  • add a smoke-report.test.ts case for {pass: 0, fail: 0, advisory: N}.

Related cosmetic point: an advisory-only run still leads with the word PASSED. Honest by design, and the caveat is on the same line, but a hurried CI scan reads green. Optional: lead with PASSED (2 UNVERIFIED).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions