Skip to content
Merged
Show file tree
Hide file tree
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
14 changes: 6 additions & 8 deletions scripts/test.js
Original file line number Diff line number Diff line change
Expand Up @@ -143,16 +143,14 @@ if (runtimeDocstrings) {
console.log("Running runtime docstrings tests");

const generated_mocha_test_res = path.join(
"tests",
"docstring_tests",
docstringTestDir,
"generated_mocha_test.res",
);

// Remove `generated_mocha_test.res` if file exists
if (fs.existsSync(generated_mocha_test_res)) {
console.log(`Removing ${generated_mocha_test_res}`);
fs.unlinkSync(generated_mocha_test_res);
}
await execClean([], {
cwd: docstringTestDir,
stdio: "inherit"
})

await execBuild([], {
cwd: docstringTestDir,
Expand Down Expand Up @@ -180,7 +178,7 @@ if (runtimeDocstrings) {

console.log("Run mocha test");
await mocha(
[path.join("tests", "docstring_tests", "generated_mocha_test.res.js")],
[path.join(docstringTestDir, "generated_mocha_test.res.js")],
{
cwd: projectDir,
stdio: "inherit",
Expand Down
3 changes: 2 additions & 1 deletion tests/build_tests/jsx_settings_inheritance/input.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import { setup } from "#dev/process";

const { execBuild } = setup(import.meta.dirname);
const { execBuild, execClean } = setup(import.meta.dirname);

await execClean()
await execBuild();
4 changes: 3 additions & 1 deletion tests/build_tests/transitive_pinned_dependency1/input.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@ import * as assert from "node:assert";
import { existsSync } from "node:fs";
import { setup } from "#dev/process";

const { execBuild } = setup("./a");
const { execBuild, execClean } = setup("./a");

await execClean()

const output = await execBuild();
console.log(output);
Expand Down
4 changes: 2 additions & 2 deletions tests/build_tests/transitive_pinned_dependency2/input.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import * as assert from "node:assert";
import { existsSync } from "node:fs";
import { setup } from "#dev/process";

const { execBuild } = setup("./a");

const { execBuild, execClean } = setup("./a");
await execClean()
const output = await execBuild();
console.log(output);

Expand Down