Skip to content

Add an opt-in gremlins mutation-test script - #67

Merged
EllAchE merged 1 commit into
mainfrom
feat/mutation-test
Nov 23, 2026
Merged

EllAchE merged 1 commit into
mainfrom
feat/mutation-test

Conversation

@EllAchE

@EllAchE EllAchE commented Nov 22, 2026

Copy link
Copy Markdown
Contributor

Why

The test suite only protects users if it fails when the code breaks. A test that stays green with a fault in release-signature checking would let a tampered update through unnoticed. Until now there was no way to measure that here.

Summary

  • scripts/mutation-test.sh <package> runs gremlins, pinned to v0.6.0 and installed into a version-keyed cache. It plants small faults in one package and lists the ones no test catches.
  • It is opt-in and report-only. CI does not run it, and a low score never fails anything.
  • A short README section says what to score (release signatures, credentials, the output contract) and what to do with each surviving mutant.

Risks

None material. It is a new script that nothing calls.

Tradeoffs

None material. Nothing runs it in CI for now, so the score is read only when someone runs the script.

Test plan

  • scripts/mutation-test.sh ./internal/release: 41 killed, 2 lived, 4 not covered. Test efficacy 95.3%, mutator coverage 91.5%, about 9 s.
  • Survivors: signature.go:41 (lines++ → lines--) and signature.go:52 (lines == 0 negated). Both only change which error message a rejected manifest gets. Signature acceptance is still fully guarded. They are left for a follow-up and not fixed here.
  • bash -n scripts/mutation-test.sh

Shares only README.md with #16 (different sections), so a merge conflict there would be trivial.

scripts/mutation-test.sh runs gremlins v0.6.0 on one package and reports
which planted faults no test catches. It is report-only and CI does not
run it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@EllAchE EllAchE added claude PR primarily authored by Claude merge:independent No known unmerged PR prerequisite. Checks, reviews, rollout approvals and holds still apply. labels Nov 22, 2026
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 22, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-22T20:29:54.482674Z 1ca8f3e PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@EllAchE
EllAchE merged commit 11d103d into main Nov 23, 2026
5 checks passed
@EllAchE
EllAchE deleted the feat/mutation-test branch November 23, 2026 08:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

claude PR primarily authored by Claude merge:independent No known unmerged PR prerequisite. Checks, reviews, rollout approvals and holds still apply.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant