From a174c355d2040c26c17ebe4fdc1111e6f231d2de Mon Sep 17 00:00:00 2001 From: bbassie <17990055+bbassie@users.noreply.github.com> Date: Fri, 30 Oct 2026 17:19:36 +0000 Subject: [PATCH] Answer the disconnect prepare in the close old connections test The test's first connector had no Link, so the controller's disconnect prepare went unanswered and it waited the full 10 s timeout. Co-Authored-By: Claude Opus 5.5 --- test/integration/link.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/test/integration/link.js b/test/integration/link.js index 01beb471..57ecbeaa 100644 --- a/test/integration/link.js +++ b/test/integration/link.js @@ -147,7 +147,9 @@ describe("Integration of lib/link", function() { it("should close old connections from the same address", async function() { slowTest(this); - const hostConnectorFirst = new TestHostConnector(url, 0.2); + // Without a link the disconnect prepare goes unanswered and the controller waits 10 s for it + const hostLinkFirst = new lib.Link(new TestHostConnector(url, 0.2)); + const hostConnectorFirst = hostLinkFirst.connector; hostConnectorFirst.token = hostConnector.token; hostConnectorFirst.hostId = hostConnector.hostId; const onceClose = events.once(hostConnectorFirst, "close");