TEST-INFRA: [test-architecture] Refactor consolidated feature files into smaller, focused files #5770

Open
opened 2026-04-09 09:19:17 +00:00 by HAL9000 · 0 comments
Owner

Metadata

  • Branch: refactor/test-arch-split-consolidated-feature-files
  • Commit Message: refactor(tests): split consolidated Behave feature files into focused, single-concern files
  • Milestone: (none — backlog, see note below)
  • Parent Epic: #5407

Description

The Behave test suite contains feature files that are consolidations of many smaller, more focused feature files. A prime example is features/consolidated_plan_model_lifecycle.feature, which combines scenarios from at least seven other feature files.

This practice has several negative consequences:

  • Reduced Readability: Large, consolidated feature files are difficult to read and understand. It's hard to get a clear picture of the feature being tested when scenarios for multiple different aspects are mixed together.
  • Increased Maintenance Burden: These files are difficult to maintain. When a change is made to a feature, it can be hard to find the relevant tests in a large, consolidated file.
  • Duplication: The consolidation process has led to the duplication of scenarios, which is a major anti-pattern in testing.

Subtasks

  • Identify all consolidated feature files in the features/ directory.
  • Split each consolidated feature file back into its original, smaller, more focused feature files.
  • Remove any duplicated scenarios that were introduced during the consolidation process.
  • Ensure that all tests still pass after the refactoring (nox -e unit_tests).
  • Verify coverage remains >= 97% (nox -e coverage_report).

Definition of Done

  • All consolidated feature files have been refactored into smaller, more focused files.
  • All duplicated scenarios have been removed.
  • The test suite is cleaner, more readable, and easier to maintain.
  • All tests pass.
  • All nox stages pass.
  • Coverage >= 97%.

Backlog note: This issue was discovered during autonomous operation
on milestone v3.8.0. It does not block milestone completion and has been
placed in the backlog for human review and future milestone assignment.


Automated by CleverAgents Bot
Supervisor: Test Infrastructure | Agent: new-issue-creator

## Metadata - **Branch**: `refactor/test-arch-split-consolidated-feature-files` - **Commit Message**: `refactor(tests): split consolidated Behave feature files into focused, single-concern files` - **Milestone**: *(none — backlog, see note below)* - **Parent Epic**: #5407 ## Description The Behave test suite contains feature files that are consolidations of many smaller, more focused feature files. A prime example is `features/consolidated_plan_model_lifecycle.feature`, which combines scenarios from at least seven other feature files. This practice has several negative consequences: - **Reduced Readability:** Large, consolidated feature files are difficult to read and understand. It's hard to get a clear picture of the feature being tested when scenarios for multiple different aspects are mixed together. - **Increased Maintenance Burden:** These files are difficult to maintain. When a change is made to a feature, it can be hard to find the relevant tests in a large, consolidated file. - **Duplication:** The consolidation process has led to the duplication of scenarios, which is a major anti-pattern in testing. ## Subtasks - [ ] Identify all consolidated feature files in the `features/` directory. - [ ] Split each consolidated feature file back into its original, smaller, more focused feature files. - [ ] Remove any duplicated scenarios that were introduced during the consolidation process. - [ ] Ensure that all tests still pass after the refactoring (`nox -e unit_tests`). - [ ] Verify coverage remains >= 97% (`nox -e coverage_report`). ## Definition of Done - [ ] All consolidated feature files have been refactored into smaller, more focused files. - [ ] All duplicated scenarios have been removed. - [ ] The test suite is cleaner, more readable, and easier to maintain. - [ ] All tests pass. - [ ] All nox stages pass. - [ ] Coverage >= 97%. > **Backlog note:** This issue was discovered during autonomous operation > on milestone v3.8.0. It does not block milestone completion and has been > placed in the backlog for human review and future milestone assignment. --- **Automated by CleverAgents Bot** Supervisor: Test Infrastructure | Agent: new-issue-creator
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
cleveragents/cleveragents-core#5770
No description provided.