coverage

package
v0.2.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 10, 2026 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Overview

Package coverage models codefit's coverage manifest (PRD section 10, RF-07): the explicit, per-language declaration of what codefit detects and what it does not. It turns the blind spot from "invisible and dangerous" into "declared and known", and is the single source for both the human-facing COVERAGE.md and the agent-facing codefit-coverage tool, and for the report's coverage_note.

Scope: this package declares the Manifest TYPE only — deliberately, not as a stub. The content lives where it is owned: each LanguageProvider supplies its own manifest (internal/providers/<lang>/coverage.go), and the DB dimension, which belongs to no language, supplies its own neutral one (internal/core/dbcoverage). The codefit-coverage tool serves them.

Known gap, stated rather than promised: report.CoverageNote is still `omitempty` and is not yet derived from a Manifest. An earlier draft of this comment asserted that would land in Fase 1. It did not.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Manifest

type Manifest struct {
	Language string
	// Deterministic lists the classes codefit detects with coded patterns
	// (certainty 1.0): hardcoded secrets, SQL/command injection, weak crypto, ...
	Deterministic []string
	// Reasoning lists the classes codefit maps as surface for the agent to
	// reason about: IDOR, broken authz, over-fetching, ...
	Reasoning []string
	// NotCovered lists, explicitly, what codefit does not audit: race
	// conditions, architectural design flaws, business-logic correctness, ...
	NotCovered []string
	// DeliveredElsewhere lists capabilities the PRD promises under one
	// identifier that codefit delivers under ANOTHER — the capability exists,
	// but not as a rule carrying the promised id (N+1 is promised as DB-201 and
	// shipped as the provider's nplus1 surface category).
	//
	// It is a third answer, not a variant of the other two. Silence would hide a
	// capability the agent could have used; NotCovered would call a shipped
	// capability absent. Each entry carries BOTH names and enough prose to
	// follow the mapping (ADR 0057).
	DeliveredElsewhere []string
}

Manifest declares, for one language, which classes of problems codefit covers and how — and, honestly, which it does not (PRD section 10).

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL