Skip to content

test: bootstrap release artifacts via Vitest globalSetup (#4)#51

Merged
Evilander merged 1 commit into
masterfrom
test/decouple-guardbench-artifacts
May 29, 2026
Merged

test: bootstrap release artifacts via Vitest globalSetup (#4)#51
Evilander merged 1 commit into
masterfrom
test/decouple-guardbench-artifacts

Conversation

@Evilander
Copy link
Copy Markdown
Owner

Summary

Decouples the release/publication integration tests in tests/guardbench.test.js (~15 tests) from the heavy pretesttest:artifacts chain. A bare vitest run now bootstraps the canonical artifacts it needs via a Vitest globalSetup.

What it generates

GuardBench results + conformance card + submission bundle + leaderboard + adapter self-test, external-adapter dry-run + evidence, behavioral-benchmark summary, arXiv source, a deterministic pending compile report, and the paper submission bundle.

What it deliberately skips (both still covered by release:gate:paper)

  • paper:sync — rewrites tracked docs/paper/*.md with machine-local benchmark numbers.
  • The real LaTeX compile — embeds a machine-local absolute path in the PDF, which fails the bundle's redaction check on the machine that compiled it.

Result

vitest run from a clean checkout (no pretest): 785 passed, 0 failed. Idempotent on re-run (artifacts present → setup skips heavy generation). lint / format:check / typecheck all clean.

🤖 Generated with Claude Code

tests/guardbench.test.js holds ~15 release/publication integration tests that
read the canonical artifact outputs produced by `npm run test:artifacts`
(GuardBench results, external-adapter evidence, arXiv source, paper submission
bundle). A bare `vitest run` without the heavy `pretest` chain left them red.

Add a Vitest globalSetup that generates exactly those artifacts on demand,
deterministically, while deliberately skipping the two environment-fragile
steps from `test:artifacts`:
  - `paper:sync`, which rewrites tracked docs/paper/*.md with machine-local
    benchmark numbers; and
  - the real LaTeX compile, which embeds a machine-local absolute path in the
    PDF (it forces a deterministic pending compile report instead).

Both remain covered by `npm run release:gate:paper`. A bare `vitest run` from a
clean checkout is now fully green (785 passed, 0 failed).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@Evilander Evilander merged commit c563a76 into master May 29, 2026
11 checks passed
@Evilander Evilander deleted the test/decouple-guardbench-artifacts branch May 29, 2026 04:02
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.

1 participant