16 lines
627 B
TypeScript
16 lines
627 B
TypeScript
import { bunEnv, bunExe } from "harness";
|
|
import path from "node:path";
|
|
|
|
test("dev server deinitializes itself", () => {
|
|
const result = Bun.spawnSync({
|
|
cmd: [bunExe(), "test", path.join(import.meta.dir, "fixtures/deinitialization/test.ts")],
|
|
env: bunEnv,
|
|
stdio: ["inherit", "inherit", "inherit"],
|
|
cwd: path.join(import.meta.dir, "fixtures/deinitialization"),
|
|
});
|
|
expect(result.signalCode).toBeUndefined();
|
|
expect(result.exitCode).toBe(0);
|
|
// The child runs a whole `bun test` suite (nine GC-heavy cases plus leak
|
|
// reporting at exit), which takes longer than the 5s default under ASAN.
|
|
}, 60_000);
|