mirror of
https://github.com/paperclipai/paperclip.git
synced 2026-10-27 11:20:42 +01:00
test(runner): handle close rejection before teardown
Attach the pending-request assertion before transport shutdown so Vitest never observes a transient unhandled rejection. Co-Authored-By: Paperclip <noreply@paperclip.ing>
This commit is contained in:
1 parent
a11f0a1142
commit
b734ed29d0
1 file changed
+2
-1
@@ -34,8 +34,9 @@ describe("Codex app-server transport limits", () => {
|
||||
await expect(transport.request("second", {})).rejects.toThrow(
|
||||
"codex app-server pending request limit 1 exceeded",
|
||||
);
|
||||
const firstRejection = expect(first).rejects.toThrow("codex app-server transport closed");
|
||||
await transport.close();
|
||||
await expect(first).rejects.toThrow("codex app-server transport closed");
|
||||
await firstRejection;
|
||||
});
|
||||
|
||||
it("fails closed when queued notifications exceed their count bound", async () => {
|
||||
|
||||
Reference in new issue
Block a user