DotCov.Fallout 4.1.0

There is a newer version of this package available.
See the version list below for details.
dotnet add package DotCov.Fallout --version 4.1.0
                    
NuGet\Install-Package DotCov.Fallout -Version 4.1.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="DotCov.Fallout" Version="4.1.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="DotCov.Fallout" Version="4.1.0" />
                    
Directory.Packages.props
<PackageReference Include="DotCov.Fallout" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add DotCov.Fallout --version 4.1.0
                    
#r "nuget: DotCov.Fallout, 4.1.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package DotCov.Fallout@4.1.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=DotCov.Fallout&version=4.1.0
                    
Install as a Cake Addin
#tool nuget:?package=DotCov.Fallout&version=4.1.0
                    
Install as a Cake Tool

Build

DotCov.Fallout

Coverage reporting and threshold gating for Fallout builds — one interface, no target wiring.

Getting started

fallout :add-package DotCov.Fallout
using DotCov.Fallout;

class Build : FalloutBuild, ICoverageReport { }
fallout ReportCoverage --coverage-min-line 80 --coverage-exclude-generated-param true

That is the whole setup. There is no default threshold: set --coverage-min-line, --coverage-min-branch, or both, or the target fails naming them before it reads a report. ReportCoverage searches RootDirectory / "TestResults" for **/*cobertura*.xml (including timestamped MTP reports and hidden directories), merges everything it finds, renders the chosen format, appends a markdown block to $GITHUB_STEP_SUMMARY when that variable is set, and fails the build when line or branch coverage is below threshold.

The target attaches itself to ICompile through TryDependsOn, so it hooks into an existing build without requiring you to implement ICompile.

Parameters

Parameter Default Effect
--coverage-min-line none Minimum line coverage percentage, 0 to 100 (invariant number); set it, --coverage-min-branch, or both
--coverage-min-branch none Minimum branch coverage percentage, 0 to 100; a dimension left unset is not checked
--coverage-format table table, json, markdown, or md; json logs the same document as dotcov check --format json, gate included
--coverage-json-path empty (off) Also write that JSON document to this file, relative to the root, for every outcome
--coverage-exclude-generated-param false true/false: apply ExclusionRules.WellKnown before gating
--coverage-exclude-test-code-param false true/false: apply ExclusionRules.TestCode before gating; the excluded files are logged
--coverage-probe-sources-param false true/false: resolve a relative file name under several <source> roots against the root that holds it on this machine's disk
--coverage-source-root empty (off) Resolve such file names against this declared root instead
--coverage-pattern **/*cobertura*.xml filename (top level) or **/filename (recursive)
--coverage-max-chars-param 50000000 Per-file XML character cap; 0 disables it
--coverage-badge-directory empty (off) Write coverage-badge.svg and coverage-badge.json here, relative to the root, for every outcome

Every value is validated once, before any report is read; an invalid value fails the target naming the parameter. Override CoverageSearchDirectory in your Build class to scan somewhere other than RootDirectory / "TestResults".

Outcomes

A failing target exits with the same code dotcov would, so a script can tell a failed gate from one that could not measure.

Situation Exit Result
Thresholds met 0 Target succeeds; the verdict is logged
Coverage below a threshold 1 Coverage below threshold: FAIL: …, then the files below it with their uncovered lines
No threshold set, one outside 0 to 100, or --coverage-source-root not declared by any report 2 Fails before reading a report, naming the parameter
No matching report, nothing measured, or a file identity unresolved across several <source> roots 3 No files matching '…' or Coverage could not be measured: NODATA: …
Every threshold is 0 4 Coverage gate is disabled …
Search directory missing, a report unreadable, or a passing gate whose badge or JSON file cannot be written 5 The error, naming the path

Parser warnings (malformed hit counts, contradictory branch data, ambiguous source roots, …) are logged one per line. Only an unresolved file identity changes the verdict, to NODATA. The badge is written before a failing verdict fails the target, so a drop turns it red; its colour is the outcome, and its message the line rate, plus the branch rate when a branch minimum is set. A non-passing gate keeps its own failure message when the badge cannot be written. To publish it to a branch, pass the directory to the badge action as badge-directory. An unwritable GITHUB_STEP_SUMMARY is logged as a warning and does not fail an otherwise passing gate. Percentages are invariant-formatted, so CI logs read 62.0% on every host, never 62,0%.

Parsing comes from DotCov: streaming XmlReader, no full-DOM load, DTDs ignored (never processed), external resolution disabled, bounded memory.

Also in this family

DotCov.Tool — the dotcov CLI · DotCov — the parser as a library

Feedback

Documentation · Issues · MIT

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
4.7.1 105 10/19/2026
4.7.0 160 10/15/2026
4.6.0 80 10/15/2026
4.5.0 101 10/15/2026
4.4.0 88 10/15/2026
4.3.2 81 10/15/2026
4.3.1 89 10/15/2026
4.3.0 81 10/14/2026
4.2.0 83 10/14/2026
4.1.0 130 10/14/2026
4.0.0 90 10/14/2026
3.0.1 89 10/14/2026
3.0.0 101 10/13/2026
2.0.0 83 10/13/2026
1.7.1 87 10/11/2026
1.7.0 90 10/11/2026
1.6.1 85 10/11/2026
1.6.0 90 10/11/2026
1.5.0 84 10/11/2026
1.4.0 92 10/11/2026
Loading failed

DotCov 4.1.0 adds to the 4.0 agent contract without changing it.
diff accepts --exclude-generated, --exclude-test-code and --keep, applied to both reports and listed as excluded/exclusionRules in JSON.
--no-color is accepted by every command that reads a report, so a script can pass it everywhere.
4.0 changed three contracts (verdict on stderr, exit 6 for a failed test run, the JSON envelope); see the 4.0.0 notes.
Full notes: https://github.com/ANcpLua/dotcov/blob/main/docs/releases/4.1.0.md