/** * Istanbul-compatible location */ export interface Location { readonly line: number; readonly column: number; } /** * Istanbul-compatible range */ export interface Range { readonly start: Location; readonly end: Location; } /** * Istanbul-compatible branch mapping */ export interface BranchMapping { readonly loc: Range; readonly type: string; readonly locations: Range[]; readonly line: number; } /** * Istanbul-compatible function mapping */ export interface FunctionMapping { readonly name: string; readonly decl: Range; readonly loc: Range; readonly line: number; } /** * Istanbul-compatible file coverage data */ export interface FileCoverageData { readonly path: string; readonly statementMap: Record; readonly fnMap: Record; readonly branchMap: Record; readonly s: Record; readonly f: Record; readonly b: Record>; } /** * Istanbul-compatible coverage */ export interface Coverage { readonly covered: number; readonly total: number; readonly coverage: number; } /** * Istanbul-compatible totals */ export interface Totals { readonly total: number; readonly covered: number; readonly skipped: number; readonly pct: number; } /** * Istanbul-compatible coverage summary data */ export interface CoverageSummaryData { readonly lines: Totals; readonly statements: Totals; readonly branches: Totals; readonly functions: Totals; } /** * Istanbul-compatible coverage summary */ export interface CoverageSummary { merge(otherSummary: CoverageSummary): CoverageSummary; toJSON(): CoverageSummaryData; isEmpty(): boolean; readonly data: CoverageSummaryData; readonly lines: Totals; readonly statements: Totals; readonly branches: Totals; readonly functions: Totals; } /** * Istanbul-compatible file coverage */ export interface FileCoverage extends FileCoverageData { readonly data: FileCoverageData; merge(other: FileCoverageData): void; getBranchCoverageByLine(): Record; getLineCoverage(): Record; getUncoveredLines(): Array; resetHits(): void; computeBranchTotals(): Totals; computeSimpleTotals(): Totals; toSummary(): CoverageSummary; toJSON(): any; }