istanbul-reports
Advanced tools
Comparing version 3.0.3 to 3.0.4
@@ -6,2 +6,9 @@ # Change Log | ||
### [3.0.4](https://www.github.com/istanbuljs/istanbuljs/compare/istanbul-reports-v3.0.3...istanbul-reports-v3.0.4) (2021-10-12) | ||
### Bug Fixes | ||
* handle reports with "loc" but no "decl" ([#637](https://www.github.com/istanbuljs/istanbuljs/issues/637)) ([cdc28f3](https://www.github.com/istanbuljs/istanbuljs/commit/cdc28f3a1e80e786eaab3b7d3b8b9b558fc2d3c8)), closes [#322](https://www.github.com/istanbuljs/istanbuljs/issues/322) | ||
### [3.0.3](https://www.github.com/istanbuljs/istanbuljs/compare/istanbul-reports-v3.0.2...istanbul-reports-v3.0.3) (2021-10-06) | ||
@@ -8,0 +15,0 @@ |
@@ -89,6 +89,9 @@ /* | ||
const type = count > 0 ? 'yes' : 'no'; | ||
const startCol = meta.decl.start.column; | ||
let endCol = meta.decl.end.column + 1; | ||
const startLine = meta.decl.start.line; | ||
const endLine = meta.decl.end.line; | ||
// Some versions of the instrumenter in the wild populate 'func' | ||
// but not 'decl': | ||
const decl = meta.decl || meta.loc; | ||
const startCol = decl.start.column; | ||
let endCol = decl.end.column + 1; | ||
const startLine = decl.start.line; | ||
const endLine = decl.end.line; | ||
const openSpan = | ||
@@ -95,0 +98,0 @@ lt + |
@@ -11,2 +11,3 @@ /* | ||
super(); | ||
opts = opts || {}; | ||
this.file = opts.file || 'lcov.info'; | ||
@@ -32,3 +33,3 @@ this.projectRoot = opts.projectRoot || process.cwd(); | ||
writer.println('TN:'); //no test nam | ||
writer.println('TN:'); | ||
const fileName = path.relative(this.projectRoot, fc.path); | ||
@@ -38,3 +39,6 @@ writer.println('SF:' + fileName); | ||
Object.values(functionMap).forEach(meta => { | ||
writer.println('FN:' + [meta.decl.start.line, meta.name].join(',')); | ||
// Some versions of the instrumenter in the wild populate 'loc' | ||
// but not 'decl': | ||
const decl = meta.decl || meta.loc; | ||
writer.println('FN:' + [decl.start.line, meta.name].join(',')); | ||
}); | ||
@@ -41,0 +45,0 @@ writer.println('FNF:' + summary.functions.total); |
{ | ||
"name": "istanbul-reports", | ||
"version": "3.0.3", | ||
"version": "3.0.4", | ||
"description": "istanbul reports", | ||
@@ -5,0 +5,0 @@ "author": "Krishnan Anantheswaran <kananthmail-github@yahoo.com>", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
286618
3810
0