Skip to content

Tests now kill 32 more Infection mutants - #132

Merged
thunderer merged 3 commits into
masterfrom
tk-escaped-mutants
Nov 7, 2026
Merged

thunderer merged 3 commits into
masterfrom
tk-escaped-mutants

Conversation

@thunderer

@thunderer thunderer commented Nov 7, 2026 •

Copy link
Copy Markdown
Owner

Infection left 160 escaped mutants on master, and the GitHub annotations listed them on every pull request diff. Tests from an earlier branch kill 25 of them. I ran each of the remaining 135 against master on 2000 random inputs through all parsers, the processor, the serializers and the facade: 7 of them change the output and can be killed by tests, the other 128 changed nothing and are most likely equivalent.

  • added tests that kill the 32 mutants, without changes in src: escaped mutants go from 160 to 128 and Covered Code MSI from 90% to 92% on PHP 8.4,
  • Infection now mutates only the lines changed by a pull request (--git-diff-lines against the base branch), so annotations show only mutants of that change, and pushes to master still run all mutants,
  • the checkout now fetches the full history, so the base branch is available for the diff,
  • Infection now runs in its own job on PHP 8.5 only, so the test matrix no longer fetches the full history or reinstalls PHPUnit after Psalm,
  • verified PHPUnit on PHP 5.5-8.5, Psalm on PHP 7.4-8.5, Mago and Infection.

This pull request changes no lines in src, so its own CI run shows how Infection handles a diff without changed sources.

@github-actions

github-actions Bot commented Nov 7, 2026

Copy link
Copy Markdown

Infection

No mutants: this pull request changes no lines in src.

@thunderer
thunderer force-pushed the tk-escaped-mutants branch 2 times, most recently from fc90a45 to 50050e6 Compare November 7, 2026 22:36
@thunderer
thunderer merged commit 2f353d9 into master Nov 7, 2026
17 checks passed
@thunderer
thunderer deleted the tk-escaped-mutants branch November 7, 2026 22:50
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