/** * Istanbul (JSON) coverage parser — Spec 15 R4. * * Parses Istanbul/nyc JSON coverage output. The format is a map of * file paths → coverage data objects with statementMap, fnMap, and hit counts. * * Format reference: https://github.com/istanbuljs/istanbuljs */ export interface IstanbulCoverage { [filePath: string]: { path: string; statementMap: Record; fnMap: Record; branchMap: Record; /** Statement hit counts: statementId → execution count */ s: Record; /** Function hit counts: functionId → execution count */ f: Record; /** Branch hit counts */ b: Record; /** Full path to the source file */ [key: string]: unknown; }; } interface ParsedFile { sourceFile: string; /** Set of covered line numbers (statement hit count > 0) */ coveredLines: Set; /** Map of function name → { line, hitCount } */ functions: Map; /** Total statements */ totalStatements: number; /** Covered statements */ coveredStatements: number; } /** * Parse Istanbul JSON coverage data string. */ export declare function parseIstanbul(content: string): ParsedFile[]; /** * Convert Istanbul parsed files to a file → covered lines map. */ export declare function istanbulToLineCoverage(files: ParsedFile[]): Map>; /** * Convert Istanbul parsed files to a file → covered function names map. */ export declare function istanbulToFunctionCoverage(files: ParsedFile[]): Map>; export {}; //# sourceMappingURL=istanbulParser.d.ts.map