test: add ut of chile process pod in StdioClientTransport

This commit is contained in:
Xiaofu Huang 2025-05-06 17:38:26 +08:00
commit 7e134f259e

View file

@ -59,3 +59,12 @@ test("should read messages", async () => {
await client.close();
});
test("should return child process pid", async () => {
const client = new StdioClientTransport(serverParameters);
await client.start();
expect(client.pid).toBeDefined();
await client.close();
expect(client.pid).toBeUndefined();
});