Class ProtoRunGateCoverageExtensions

Namespace
ProtoTest.Core
Assembly
ProtoTest.Core.dll

Coverage helpers for Run gates. Coverage is one kind of collected evidence among several, so its arithmetic lives here rather than on ProtoRunGateContext.

public static class ProtoRunGateCoverageExtensions
Inheritance
ProtoRunGateCoverageExtensions
Inherited Members

Methods

CoverageFor(ProtoRunGateContext, string)

Gets the coverage of one target, or null when it recorded none. A target may report several categories, so the result aggregates all of them rather than picking one.

public static ProtoCoverageSummary? CoverageFor(this ProtoRunGateContext context, string targetName)

Parameters

context ProtoRunGateContext
targetName string

Returns

ProtoCoverageSummary

CoverageFor(ProtoRunGateContext, string, string)

Gets the coverage of one target in one category, or null when it recorded none.

public static ProtoCoverageSummary? CoverageFor(this ProtoRunGateContext context, string targetName, string category)

Parameters

context ProtoRunGateContext
targetName string
category string

Returns

ProtoCoverageSummary

CoverageSummaries(ProtoRunGateContext)

Aggregates the collected coverage items per target and category. Items whose verdict is unknown (IsCovered is null) are aggregates rather than units, so they are left out entirely, exactly as the report summary leaves them out.

public static IReadOnlyList<ProtoCoverageSummary> CoverageSummaries(this ProtoRunGateContext context)

Parameters

context ProtoRunGateContext

Returns

IReadOnlyList<ProtoCoverageSummary>