chore: fix tests for latest tap

Gar committed Aug 5, 2024 at 10:23 UTC 627eda0eafe0143e1948589a797ed76433b2c0ac
3 files changed +3 -6
cli/package.json
+1 -4
@@ -48,9 +48,6 @@
48 "lib/"
49 ],
50 "tap": {
51 - "nyc-arg": [
52 - "--exclude",
53 - "tap-snapshots/**"
54 - ]
51 + "allow-incomplete-coverage": true
52 }
53 }
cli/test/index.js
+1 -1
@@ -66,7 +66,7 @@ const mockBuild = async (t, {releases = getReleases(), packument = {}, testdir:
66 return yaml.stringify(children).replace(new RegExp(`/cli/${id}/`, 'g'), '/')
67 }
68
69 - const build = t.mock('../lib/build', {
69 + const build = t.mockRequire('../lib/build', {
70 pacote: {
71 ...pacote,
72 packument: async () => {
cli/test/transform.js
+1 -1
@@ -2,7 +2,7 @@ const t = require('tap')
2 const fm = require('front-matter')
3
4 const transform = ({id, path}) => {
5 - const Transform = t.mock('../lib/transform', {
5 + const Transform = t.mockRequire('../lib/transform', {
6 '../lib/gh.js': {nwo: 'npm/cli'},
7 })
8 const transformed = Transform.sync('---\n---\n', {