mirror of
https://github.com/oven-sh/bun
synced 2026-02-10 19:08:50 +00:00
16 lines
480 B
JavaScript
16 lines
480 B
JavaScript
import { $ } from "bun";
|
|
import { bunExe } from "harness";
|
|
|
|
test("child_process ipc", async () => {
|
|
const output = await $`${bunExe()} ${import.meta.dir}/fixtures/ipc_fixture.js`.text();
|
|
// node (v23.4.0) has identical output
|
|
expect(output).toMatchInlineSnapshot(`
|
|
"Parent received: {"status":"Child process started"}
|
|
Child process exited with code 0
|
|
send returned false
|
|
uncaughtException ERR_IPC_CHANNEL_CLOSED
|
|
cb ERR_IPC_CHANNEL_CLOSED
|
|
"
|
|
`);
|
|
});
|