mirror of
https://github.com/ubiquitarianism/leonida.git
synced 2026-11-27 00:15:51 +01:00
[PR #987] semantic_mutants: reject zero-test baselines (MUTANTS-ZERO-TEST-BASELINE) #1023
Labels
No labels
bug
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
starred/leonida#1023
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/ubiquitarianism/leonida/pull/987
Author: @TheGeogeo
Created: 11/24/2026
Status: 🔄 Open
Base:
main← Head:fix/semantic-mutants-zero-test-baseline📝 Commits (1)
e8fa6b1semantic_mutants: reject zero-test baselines📊 Changes
2 files changed (+26 additions, -11 deletions)
View changed files
📝
tests/test_semantic_mutants.py(+23 -10)📝
tools/semantic_mutants.py(+3 -1)📄 Description
Claimed in the coordination issue as: MUTANTS-ZERO-TEST-BASELINE — https://github.com/ubiquitarianism/leonida/issues/14#issuecomment-7137474008
What and why
When
setUpClassskips the only test class before any test starts,unittestreportsRan 0 testsand exits successfully.semantic_mutants.pythen runs the mutations against that empty baseline and reports them all as survivors. Recognize the zero-test summary as a baseline error and stop before running mutants. A synthetic CLI regression checks the exit code, diagnostic and absence of mutant results.Tested
After a rebase on
main6293c1c4(e8fa6b12, same patch asf2346123), on Windows 11, Python 3.12.4:tests/test_semantic_mutants.py21 OK;test_tool_stdout_encoding.py,test_docs_cli_flags.pyandtest_text_write_line_endings.pyOK;git diff --checkand the no-game-data check clean.mainatcf4c00cb, the synthetic regression returned 1 and reported three survivors. It now returns 2 withno tests ran.python -I -B tests/test_semantic_mutants.py: 21 passed.python -I -B tests/test_run_semantic_tests.py: 19 passed. The nested failing fixture is intentional.1f76d4a7in a temporary worktree: clean application, 22 mutation-tool tests and 20 semantic-runner tests passed.git diff --checkandpython -I -B scripts/check_no_game_data.py tools/semantic_mutants.py tests/test_semantic_mutants.py: passed.GPUs tested: n/a (CPU-only test tooling)
AI-assisted: yes (Codex).
Checklist
mainwhen branched; two-file diff checked againstmainbefore publication.🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.