Skip to content

Use module-level test functions - #2655

Merged
adamtheturtle merged 2 commits into
mainfrom
flatten-simple-test-classes
Oct 6, 2026
Merged

adamtheturtle merged 2 commits into
mainfrom
flatten-simple-test-classes

Conversation

@adamtheturtle

@adamtheturtle adamtheturtle commented Oct 6, 2026 •

Copy link
Copy Markdown
Member

Convert 11 stateless classes containing 42 static test methods into module-level functions as preparation for Karva. Retain pytest, fixture inputs, test markers, runtime type checks, assertions, and coverage gates.

Group tests into files by API area or behavior. Keep small, cohesive modules together and put genuinely shared helpers in support modules. Remove the organising comments and retain meaningful context in module or test docstrings. Restore shorter function names where the file supplies the context, and retain operation context only where names would collide. Preserve module-local fixture reach when files move.

Validation: before and after collection contains the same 157 cases, including parametrized cases. Independent comparisons against the original tests preserve executable statements and decorators after accounting for function names and moved helper and constant names. Applicable Prek pre-commit and pre-push checks and the manual Pylint hook pass.

The full suite passes with the existing 100% line and branch coverage gate.

@adamtheturtle
adamtheturtle merged commit 86d67a8 into main Oct 6, 2026
13 checks passed
@adamtheturtle
adamtheturtle deleted the flatten-simple-test-classes branch October 6, 2026 09:59

This branch was successfully deployed

1 active deployment
development — 82d27f7b Deployed Oct 6, 2026 by adamtheturtle via pages #1598
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