test(dap): assert terminal output stays bounded

This commit is contained in:
can1357
2026-08-13 01:02:57 +02:00
parent 78d1d0dcf5
commit 3bcdc3629c
@@ -412,7 +412,11 @@ describe("DAP multi-session debugging", () => {
expect(spawnSpy).toHaveBeenCalledTimes(1);
expect(spawnSpy.mock.calls[0]?.[0]).toEqual(["/usr/bin/debuggee", "--verbose"]);
expect(manager.getOutput().output).toContain(marker);
const output = manager.getOutput();
expect(output.output).toContain(marker);
expect(output.snapshot.outputBytes).toBeGreaterThan(128 * 1024);
expect(output.snapshot.outputTruncated).toBe(true);
expect(Buffer.byteLength(output.output, "utf-8")).toBeLessThanOrEqual(128 * 1024);
await manager.terminate(undefined, 1_000);
});