Skip to content

Commit db01b5d

Browse files
committed
Try that now
1 parent 6baebc3 commit db01b5d

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

gulp/tasks/unit.js

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,15 +21,16 @@ const unit = async function() {
2121
`nyc --include node_modules/${name} --exclude !node_modules/${name} ava`,
2222
)
2323

24-
const content = await promisify(readFile)(COVMAP_PATH, { encoding: 'utf-8' })
25-
const contentA = content.replace(
26-
/node_modules(\/|\\)log-process-errors(\/|\\)/gu,
27-
'',
28-
)
24+
const covMap = await promisify(readFile)(COVMAP_PATH, { encoding: 'utf-8' })
25+
const covMapA = covMap.replace(NESTED_REGEXP, '')
2926

30-
await gulpExeca('coveralls', { input: contentA })
27+
await gulpExeca('coveralls', { input: covMapA })
3128
}
3229

30+
const NESTED_REGEXP = new RegExp(
31+
`node_modules(\\/|\\\\)${name}(\\/|\\\\)`,
32+
'gu',
33+
)
3334
const COVMAP_PATH = './coverage/lcov.info'
3435

3536
// eslint-disable-next-line fp/no-mutation

0 commit comments

Comments
 (0)