diff options
Diffstat (limited to 'test/bundler/api.test.ts')
| -rw-r--r-- | test/bundler/api.test.ts | 20 | 
1 files changed, 10 insertions, 10 deletions
| diff --git a/test/bundler/api.test.ts b/test/bundler/api.test.ts index dee37dad5..8c8c01b42 100644 --- a/test/bundler/api.test.ts +++ b/test/bundler/api.test.ts @@ -66,6 +66,16 @@ describe("Bun.build", () => {      Bun.gc(true);    }); +  test("Bun.write(BuildArtifact)", async () => { +    Bun.gc(true); +    const x = await Bun.build({ +      entrypoints: [join(import.meta.dir, "./fixtures/trivial/index.js")], +    }); +    await Bun.write("/tmp/bun-build-test-write.js", x.outputs[0]); +    expect(readFileSync("/tmp/bun-build-test-write.js", "utf-8")).toMatchSnapshot(); +    Bun.gc(true); +  }); +    test("rebuilding busts the directory entries cache", () => {      Bun.gc(true);      const { exitCode, stderr } = Bun.spawnSync({ @@ -188,16 +198,6 @@ describe("Bun.build", () => {    //   Bun.gc(true);    // }); -  test("Bun.write(BuildArtifact)", async () => { -    Bun.gc(true); -    const x = await Bun.build({ -      entrypoints: [join(import.meta.dir, "./fixtures/trivial/index.js")], -    }); -    Bun.write("/tmp/bun-build-test-write.js", x.outputs[0]); -    expect(readFileSync("/tmp/bun-build-test-write.js", "utf-8")).toMatchSnapshot(); -    Bun.gc(true); -  }); -    test("new Response(BuildArtifact) sets content type", async () => {      const x = await Bun.build({        entrypoints: [join(import.meta.dir, "./fixtures/trivial/index.js")], | 
