diff --git a/cli/package.json b/cli/package.json index b01cbf59b90..6ff07e913ca 100644 --- a/cli/package.json +++ b/cli/package.json @@ -48,9 +48,6 @@ "lib/" ], "tap": { - "nyc-arg": [ - "--exclude", - "tap-snapshots/**" - ] + "allow-incomplete-coverage": true } } diff --git a/cli/test/index.js b/cli/test/index.js index df2dc7cf633..9d1425ba435 100644 --- a/cli/test/index.js +++ b/cli/test/index.js @@ -66,7 +66,7 @@ const mockBuild = async (t, {releases = getReleases(), packument = {}, testdir: return yaml.stringify(children).replace(new RegExp(`/cli/${id}/`, 'g'), '/') } - const build = t.mock('../lib/build', { + const build = t.mockRequire('../lib/build', { pacote: { ...pacote, packument: async () => { diff --git a/cli/test/transform.js b/cli/test/transform.js index 9dbb6885f2f..2f6e1fc62d4 100644 --- a/cli/test/transform.js +++ b/cli/test/transform.js @@ -2,7 +2,7 @@ const t = require('tap') const fm = require('front-matter') const transform = ({id, path}) => { - const Transform = t.mock('../lib/transform', { + const Transform = t.mockRequire('../lib/transform', { '../lib/gh.js': {nwo: 'npm/cli'}, }) const transformed = Transform.sync('---\n---\n', {