Skip to content

[Task]: Refactor ModularityKit.Mutator.Tests into focused fixtures #47

Description

@rian-be

Summary

Refactor ModularityKit.Mutator.Tests into smaller, runtime focused fixtures so core execution, policy, audit, side effect, and concurrency coverage remain readable and maintainable.

Goal

Improve maintainability of core Mutator tests by decomposing broad fixtures, extracting stable package-local test support where repetition is real, and aligning file boundaries with core runtime concerns.

Problem

ModularityKit.Mutator.Tests is the broadest test package in the repository and covers several core runtime behaviors that will continue to grow. Without more focused fixtures and clearer local support, the package becomes harder to scan, harder to extend safely, and harder to debug when core runtime behavior changes.

Scope

  • Split oversized or mixed core runtime test fixtures into focused files by concern
  • Isolate execution, policy, audit, side-effect, and concurrency scenarios where they are currently bundled too broadly
  • Extract stable package-local test support when setup or helper data repeats inside the package
  • Normalize naming so core runtime test files and fixtures match the scenario they cover
  • Keep refactoring scoped to ModularityKit.Mutator.Tests

Design Expectations

  • Test decomposition should preserve runtime behavior while making scenario intent clearer.
  • Helpers should be extracted only where they remove real duplication.
  • Core runtime tests should stay easy to trace when failures occur in execution, policy, or audit behavior.
  • File names and fixture names should reflect runtime concerns rather than mixed utility buckets.

Acceptance Criteria

  • ModularityKit.Mutator.Tests no longer relies on oversized mixed-concern fixtures for its core runtime scenarios
  • Execution, policy, audit, side effect, and concurrency scenarios live in focused test files or fixtures
  • Repeated package-local setup is extracted only where it improves readability and reuse
  • Naming across the package is more consistent and runtime oriented

Non Goals

  • This issue does not change core runtime behavior or public APIs
  • This issue does not refactor governance package tests outside the core test project
  • This issue does not force all package test support into one global shared helper layer

Metadata

Metadata

Assignees

Labels

testsTest coverage and test changes

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions