Skip to content

test(backend): reorganize tests to mirror business/ file structure - #320

Merged
littlecoffe8 merged 1 commit into
mainfrom
tests/mirror-business-structure
Aug 20, 2026
Merged

test(backend): reorganize tests to mirror business/ file structure#320
littlecoffe8 merged 1 commit into
mainfrom
tests/mirror-business-structure

Conversation

@littlecoffe8

Copy link
Copy Markdown
Collaborator

Description

Splits the 495-line test_knowledge_panel.py (22 tests covering everything end-to-end) into one file per module under test, mirroring the calculators/ and panel_renderer/ split from previous refacto

Code changes

  • calculators/test_pain_report_calculator.py
  • calculators/test_breeding_type_calculator.py
  • calculators/test_egg_quantity_calculator.py
  • calculators/test_product_type_calculator.py
  • calculators/test_unit_pain_loader.py
  • panel_renderer/test_generator.py
  • test_knowledge_panel_service.py (renamed, now only covers knowledge_panel_service.py)
  • tests/conftest.py fixtures stay centralized and unchanged

How to test

Same 22 test functions, same assertions, same parametrization - verified by diffing the sorted list of test function names before/after (identical, no gaps, no duplicates). Full suite: 59 passed. ruff check --fix produces no further changes.

@littlecoffe8
littlecoffe8 merged commit 5110fe8 into main Aug 20, 2026
2 checks passed
@littlecoffe8
littlecoffe8 deleted the tests/mirror-business-structure branch August 20, 2026 08:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant