Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
fraxy-v committed Sep 1, 2024
1 parent 4906be6 commit 08cb248
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions scripts/check-coverage.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,11 @@ module.exports = async (sources, covFile) => {
let file = package.$.name;
for (let classes of package.classes) {
for (let clazz of classes.class) {
let file = package.$.name + '/' + clazz.$.filename;
for (let lines of clazz.lines) {
for (let line of lines.line) {
if (line.$.hits === '0') {
console.log(`Uncovered line in ${file}:${line.$.number}`);
if (sources.find(source => source.file === file && source.lines.includes(parseInt(line.$.number)))) {
if (sources.find(source => source.file === clazz.$.filename && source.lines.includes(parseInt(line.$.number)))) {
console.error(`Uncovered line in ${file}:${line.$.number}`);
// Found an uncovered line in a changed file
return false;
Expand Down

0 comments on commit 08cb248

Please sign in to comment.