Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions scripts/publish.test.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,15 @@ function fixture(t) {
cpSync(`packages/${name}/package.json`, path);
const pkg = read(path);
pkg.version = '2.0.0';
// Drop packaging lifecycle scripts. The fixture exists to exercise
// pack-release's OWN assertions, and `npm pack --ignore-scripts` was still
// running `prepare` -> `bun run build` -> `tsc` on a CI runner, so npm
// failed before the script could report `missing package/dist/index.js`.
// It passed locally only because this machine happened to have the
// toolchain the fixture does not install.
for (const hook of ['prepare', 'prepack', 'postpack', 'prepublishOnly']) {
delete pkg.scripts?.[hook];
}
writeFileSync(path, JSON.stringify(pkg));
}
return root;
Expand Down
Loading