frostney / frostney/GocciaScript

Enforce coverage scope and line/branch thresholds

Open
#1,041 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

internal new feature
Dominant language
Pascal
Stars
20
Forks
3
Avg merge
3d 4h
Merged PRs (30d)
45

Description

Summary

Let GocciaTestRunner define the source scope for coverage and fail when configured line or branch coverage thresholds are not met.

Why

Coverage reports are informative today but cannot enforce a CI quality gate. Explicit source scope is also needed so thresholds include intended production modules without being diluted by generated, fixture, or unrelated files.

Current behavior

TGocciaCoverageTracker records executable-line and branch hits. The CLI can enable coverage and write text, LCOV, or JSON output, but exposes no include/exclude patterns, thresholds, or coverage-based exit status.

Expected behavior

  • Configure include and exclude patterns for coverage source files.
  • Configure overall and per-file thresholds for line and branch coverage.
  • Print actionable threshold failures and exit non-zero after test execution when any required threshold is missed.
  • Apply thresholds to merged coverage from serial and --jobs execution.
  • Preserve source-map and multifile attribution in the scoped totals.
  • Keep text, LCOV, and JSON report generation available when enforcement fails.

Scope notes

  • Function and statement instrumentation are not currently tracked and are out of scope; they should be proposed separately if needed.
  • Coverage upload services, trend storage, custom reporters, and test-result reporters are out of scope.
  • Threshold configuration should follow existing CLI/config-file conventions rather than introduce a second configuration system.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing GocciaTestRunner and TGocciaCoverageTracker, then review the existing CLI and config-file conventions and coverage report paths. Done means scoped coverage, overall and per-file line and branch thresholds, actionable failures with a non-zero exit status, merged serial and --jobs results, and text, LCOV, and JSON reports still available.

Written by the indexing model from the issue text.

Assessment

Domain
cli, testing
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.