Skip to content

Feature: quickfiler-80-per-file-coverage #136

Description

@drmoisan
  • Work Mode: full-feature

Problem / Why

QuickFiler has a broad production surface across controllers, helper classes, interfaces, legacy code, and WinForms-adjacent viewer files, but the current QuickFiler.Test project only covers a small portion of that surface. This leaves many production files below the repository's coverage expectations and makes behavior changes harder to review safely.

This is a large-path feature, not a bugfix. The goal is to add deterministic unit coverage so every production file compiled by QuickFiler.csproj reaches at least 80% line coverage while retaining or improving the repository-wide coverage expectations defined by the repo unit-test policies.

Proposed Behavior

Add or expand MSTest coverage in QuickFiler.Test so the tests document and protect the behavior of QuickFiler one production file at a time. Because the scope is explicitly large-path and repository context is limited, research and planning must proceed one production file at a time: each production file gets its own research artifact, its own atomic-plan phase, and each individual test case is planned and executed as an atomic step.

New and updated tests must follow the repository C# testing conventions: MSTest for the framework, Moq for mocking and stubbing when isolation requires it, and FluentAssertions for new assertions where practical. The work should cover positive-path, invalid-input, edge/boundary, and error-handling behavior for each file while keeping tests deterministic, isolated, free of external dependencies, and free of temporary-file usage.

Acceptance Criteria

  • Every production .cs file compiled by QuickFiler\QuickFiler.csproj reaches at least 80% line coverage in the final verified coverage evidence for this feature.
  • Coverage research and implementation planning proceed one production file at a time because of context constraints, with a separate research artifact and a separate atomic-plan phase for each production file.
  • Within each per-file phase, each test case is defined and executed as an atomic step rather than as a broad batch task.
  • All new or updated QuickFiler tests use MSTest conventions, Moq for mocks/stubs where needed, and FluentAssertions for new assertions where practical.
  • All tests added for this feature are deterministic, isolated, fast, and independent of external services, external processes, mutable shared state, and temporary files.
  • Test coverage for each production file includes the positive path plus invalid-input, edge/boundary, and error-handling behavior that can be exercised without violating repository test-policy constraints.
  • The required C# validation loop passes in final form for the completed work: formatting, analyzer build, nullable/type-safety build, and coverage-enabled test execution.
  • Repository-wide coverage expectations are retained or improved while the QuickFiler per-file >= 80% target is achieved.

Constraints & Risks

  • The scope is explicitly large-path, so the work must be decomposed into file-sized slices rather than attempted as a single monolithic coverage push.
  • QuickFiler includes UI-heavy and legacy areas, which may require careful isolation, existing seams, or narrowly scoped testability work before deterministic unit tests can reach the target.
  • Repository policy requires tests to avoid external dependencies and temporary files, so branches that depend on live UI, filesystem temp data, or other runtime-only infrastructure may need special handling during research.
  • Because success is measured per production file as well as against repository-wide coverage expectations, aggregate coverage improvement alone is not sufficient.

Test Conditions

  • Unit coverage for each QuickFiler production file, evaluated one file at a time with matching per-file research and planning artifacts.
  • Controller, helper-class, interface-adjacent, legacy, and viewer scenarios that require positive-path, invalid-input, boundary, and error-behavior coverage without live external dependencies.
  • Mocked or in-memory scenarios for UI-adjacent and dependency-heavy code paths so the tests remain deterministic, isolated, and compliant with the no-temp-files rule.

Source

From: docs/features/potential/2026-04-20-quickfiler-80-per-file-coverage.md

Metadata

Metadata

Assignees

No one assigned

    Labels

    featureFeature request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions