From 950a5e4c5acc885cc856cf0bb2621eddc9fc053f Mon Sep 17 00:00:00 2001 From: "H. Shay" Date: Mon, 30 Sep 2024 13:38:00 -0700 Subject: [PATCH] time in tests --- test/integration/commands/makedminCommandTest.ts | 2 +- test/integration/protectionSettingsTest.ts | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/test/integration/commands/makedminCommandTest.ts b/test/integration/commands/makedminCommandTest.ts index 3c23503e..d447d352 100644 --- a/test/integration/commands/makedminCommandTest.ts +++ b/test/integration/commands/makedminCommandTest.ts @@ -34,7 +34,7 @@ describe("Test: The make admin command", function () { await moderator.sendMessage(this.mjolnir.managementRoomId, { msgtype: 'm.text.', body: `!mjolnir rooms add ${targetRoom}` }); LogService.debug("makeadminTest", `Adding targetRoom: ${targetRoom}`); // allow bot time to join room - await new Promise(resolve => setTimeout(resolve, 1000)); + await new Promise(resolve => setTimeout(resolve, 5000)); try { await moderator.start(); await userA.start(); diff --git a/test/integration/protectionSettingsTest.ts b/test/integration/protectionSettingsTest.ts index 0afcb1c5..342dcfe2 100644 --- a/test/integration/protectionSettingsTest.ts +++ b/test/integration/protectionSettingsTest.ts @@ -144,6 +144,7 @@ describe("Test: Protection settings", function() { settings = { test: new StringProtectionSetting() }; }); + await new Promise(resolve => setTimeout(resolve, 5000)); let replyPromise: Promise = new Promise((resolve, reject) => { let i = 0; client.on('room.message', noticeListener(this.mjolnir.managementRoomId, (event) => {