test: kill mutants#78
Conversation
Add tests for kebab_name() covering lowercase conversion, underscore-to-hyphen replacement, and all enum members. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…surviving mutants Add direct tests for _decode_temperature and _check_length helpers. Kill survived mutants for encode_temperature modulus, decode_temp_unit unit=None, decode_flame_effect pulsating & vs |, and encode_heat_settings boost floor max(0,...) vs max(1,...). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…ecycle, _request, and turn_on/off Add tests covering _parse_fire_features (all 24 fields), client __init__/__aenter__/__aexit__ lifecycle, _request auth/error handling, get_fires/get_fire_overview field-level verification, write_parameters, and turn_on/turn_off with mode/temperature preservation. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Tighten assertions in widget format and CLI display tests to use exact string equality instead of substring checks. This kills mutants that prepend/append "XX" to string literals (e.g., label names, separator characters, color names). Also adds boundary tests for duration=1 to kill `> 0` vs `> 1` mutations. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Verify exact subprocess.run arguments in _resolve_version tests to kill string and kwarg mutations. Add _expand_flame unit tests for gap distribution, style application, and boundary conditions. Add heat indicator wave character tests for _build_fire_art. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
… mutants - Use exact separator width checks (== instead of in) for all display functions - Add error byte isolation tests to kill bitwise OR→AND mutants - Verify timer off-at time is in the future (kills +→− and format mutants) - Add exact Yes/No and Active Faults line checks - Verify main() passes args correctly to async_main and asyncio.run - Add _expand_flame boundary tests for zero-weight and remaining_weight edge cases - Use exact rounding assertion for _convert_to_celsius - Verify _log_response preserves body preview with += (kills +=→= mutant) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Use duration=120 to kill // 60 → // 61 mutant (120//60=2 vs 120//61=1) - Use exact log record message comparison to kill format string XX mutant Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…ometry - Verify exact heat row wave character content (kills ≈→XX≈XX, ~→XX~XX) - Check heat row bright_red style (kills style mutations) - Verify heat rows reduce flame budget while maintaining total height - Assert dim style on all structural frame elements (top edge, borders, hearth) - Test flame row centering, min width, and trailing pad calculations - Test exact boundary: flame_rows_effective == num_defs (kills >= vs >) - Verify default parameter values produce expected styling Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…ions - Check ALL frame chars (│┌┐└┘─▁) have exactly 'dim' style (not just first) - Verify flame row inner width equals iw exactly (kills lead/trail mutations) - Assert leading/trailing padding is spaces only (kills ' '→'XX XX') - Verify centering: lead <= trail + 1 (kills +body_w and //3 mutations) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…etry - Use exact style equality for heat row bright_red check - Add narrow width test (w=20) to trigger min_w binding constraint - Add wide width test (w=80) to kill //2 → //3 centering mutant Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…exts - Verify prompt output, star echoing, terminal restore, and raw mode setup - Assert stdin.read called with exactly 1 character - Check backspace sequence (\b \b) written to stdout - Verify parser description contains expected strings - Verify --verbose flag has descriptive help text Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
Generated by Claude Code, has been reviewed PR Comparison: Copilot #76 vs Our #78Scope
Files unique to Copilot: Files unique to Ours: Overlapping files (both modify): Key Differences by Area1. Test Assertion Quality
2. Separator Width Mutants (
|
| Approach | Kills String XX Mutants | Kills Separator Width | Kills Timer Arithmetic | Kills Bitwise OR→AND |
|---|---|---|---|---|
| Ours | Yes (exact ==) |
Yes | Yes | Yes |
| Copilot | Partially (in checks remain) |
No | Partially | Partially |
Recommendation
Our PR #78 is the better version for the stated goal of killing mutants, because:
-
It modifies existing tests to strengthen assertions, rather than just adding new tests alongside weak ones. This is the single biggest difference — Copilot leaves the original weak
in-check tests in place. -
It kills separator width mutants (
* 40→* 41) which Copilot does not, since"─" * 40 in " " + "─" * 41is stillTrue. -
It verifies timer off-at values against
now + durationto kill the+→−mutant. -
It covers more visual/widget areas (fireplace art, heat rows, flame geometry) that Copilot skips entirely.
Copilot #76 has some advantages:
- Auth tests (
test_auth.py) that we don't have — but these target unmapped functions - More DRY parametrized
_parse_fire_featurestest - Slightly more
_resolve_versionedge cases
Best option: Cherry-pick Copilot's test_auth.py additions and the parametrized _parse_fire_features test into our branch, since those are complementary additions we don't duplicate. The rest of Copilot's changes would be weaker replacements for what we already have.
I think Claude is wrong here. If I revert those test additions in test_auth.py, the number of mutants escaping goes up. |
Cherry-pick auth tests from Copilot PR #76 that complement our existing mutation testing coverage with direct unit tests for auth internals. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
No description provided.