Fix unhandled promise rejection in Link tests

This commit is contained in:
Hornwitser committed 2024-10-28 20:15:33 +01:00
1 parent 3838bc6a70
commit 60e5ed008d
1 file changed
+1
+1
View File
@@ -127,6 +127,7 @@ describe("Integration of lib/link", function() {
hostConnectorFirst.token = hostConnector.token;
hostConnectorFirst.hostId = hostConnector.hostId;
const onceClose = events.once(hostConnectorFirst, "close");
onceClose.catch(() => {}); // Prevent unhandled promise rejection.
await hostConnectorFirst.connect();
await hostConnector.connect();
await assert.rejects(