File tree Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -17,17 +17,20 @@ const unit = async function() {
1717 return gulpExeca ( 'ava' )
1818 }
1919
20- await pack (
21- `nyc --include node_modules/${ name } --exclude !node_modules/${ name } ava` ,
22- )
20+ await pack ( `nyc --include ${ NESTED_DIR } --exclude !${ NESTED_DIR } ava` )
2321
22+ await sendToCoveralls ( )
23+ }
24+
25+ const sendToCoveralls = async function ( ) {
2426 const covMap = await promisify ( readFile ) ( COVMAP_PATH , { encoding : 'utf-8' } )
25- const covMapA = covMap . replace ( NESTED_REGEXP , '' )
27+ const covMapA = covMap . replace ( NESTED_DIR_REGEXP , '' )
2628
2729 await gulpExeca ( 'coveralls' , { input : covMapA } )
2830}
2931
30- const NESTED_REGEXP = new RegExp (
32+ const NESTED_DIR = `node_modules/${ name } `
33+ const NESTED_DIR_REGEXP = new RegExp (
3134 `node_modules(\\/|\\\\)${ name } (\\/|\\\\)` ,
3235 'gu' ,
3336)
You can’t perform that action at this time.
0 commit comments