diff --git a/scripts/local-release.mjs b/scripts/local-release.mjs
index 3f35e80c..516e7467 100644
--- a/scripts/local-release.mjs
+++ b/scripts/local-release.mjs
@@ -22,6 +22,7 @@ Options:
--out
Output directory. Defaults to a new directory under ${tmpdir()}
--force Remove --out first if it already exists
--skip-check Do not run npm run check before building
+ --skip-test Do not run ./test.sh before building
--skip-install Only create tarballs; do not create isolated installs
--skip-bun-install Do not create the isolated Bun install
--help Show this help
@@ -29,7 +30,14 @@ Options:
}
function parseArgs() {
- const options = { force: false, outDir: undefined, skipBunInstall: false, skipCheck: false, skipInstall: false };
+ const options = {
+ force: false,
+ outDir: undefined,
+ skipBunInstall: false,
+ skipCheck: false,
+ skipInstall: false,
+ skipTest: false,
+ };
const args = process.argv.slice(2);
for (let i = 0; i < args.length; i++) {
@@ -46,6 +54,10 @@ function parseArgs() {
options.skipCheck = true;
continue;
}
+ if (arg === "--skip-test") {
+ options.skipTest = true;
+ continue;
+ }
if (arg === "--skip-install") {
options.skipInstall = true;
continue;
@@ -201,6 +213,10 @@ if (!options.skipCheck) {
run("npm", ["run", "check"], { cwd: repoRoot });
}
+if (!options.skipTest) {
+ run("./test.sh", [], { cwd: repoRoot });
+}
+
for (const pkg of packages) {
run("npm", ["run", "clean"], { cwd: pkg.directory });
run("npm", ["run", "build"], { cwd: pkg.directory });
diff --git a/scripts/release.mjs b/scripts/release.mjs
index cae598bf..25ef7353 100755
--- a/scripts/release.mjs
+++ b/scripts/release.mjs
@@ -11,7 +11,7 @@
* 2. Bump version via npm run version:xxx or set an explicit version
* 3. Update CHANGELOG.md files: [Unreleased] -> [version] - date
* 4. Regenerate release artifacts
- * 5. Run checks
+ * 5. Run checks and tests
* 6. Commit and tag the release
* 7. Add new [Unreleased] section to changelogs
* 8. Commit next-cycle changelog updates
@@ -172,11 +172,15 @@ run("npm run shrinkwrap:coding-agent");
run("npm run install-lock:coding-agent");
console.log();
-// 5. Run checks
+// 5. Run checks and tests
console.log("Running checks...");
run("npm run check");
console.log();
+console.log("Running tests...");
+run("./test.sh");
+console.log();
+
// 6. Commit and tag
console.log("Committing and tagging...");
stageChangedFiles();