Skip to content

Jitsi Meet - Secure, Simple and Scalable Video Conferences that you use as a standalone app or embed in your web application.

fix(tests): Update lobby test. (#16618)

Дамян Минковa58b0d9a8582
diff --git a/tests/helpers/Participant.ts b/tests/helpers/Participant.ts
index 008b60a3f3..4b02100027 100644
--- a/tests/helpers/Participant.ts
+++ b/tests/helpers/Participant.ts
@@ -678,9 +678,9 @@ export class Participant {
* Hangups the participant by leaving the page. base.html is an empty page on all deployments.
*/
async hangup() {
- console.log('Hanging up');
+ console.log(`Hanging up (${this.name})`);
if ((await this.driver.getUrl()).endsWith('/base.html')) {
- console.log('Already hung up');
+ console.log(`Already hung up (${this.name})`);
return;
}
@@ -705,7 +705,7 @@ export class Participant {
timeoutMsg: `${this.name} failed to hang up`
}
);
- console.log('Hung up');
+ console.log(`Hung up (${this.name})`);
await this.driver.url('/base.html')
diff --git a/tests/specs/moderation/lobby.spec.ts b/tests/specs/moderation/lobby.spec.ts
index 5b0b19b3bd..c89cc76ea4 100644
--- a/tests/specs/moderation/lobby.spec.ts
+++ b/tests/specs/moderation/lobby.spec.ts
@@ -154,23 +154,25 @@ describe('Lobby', () => {
await p1.getNotifications().waitForHideOfKnockingParticipants();
});
- it('conference ended in lobby', async () => {
+ it('lobby persistence', async () => {
const { p1, p2 } = ctx;
await enterLobby(p1, false);
+ const { p3 } = ctx;
+
+ expect(await p3.getLobbyScreen().isLobbyRoomJoined()).toBe(true);
+
await p1.hangup();
await p2.hangup();
- const { p3 } = ctx;
-
await p3.driver.$('.dialog.leaveReason').isExisting();
await p3.driver.waitUntil(
async () => !await p3.getLobbyScreen().isLobbyRoomJoined(),
{
timeout: 2000,
- timeoutMsg: 'p2 did not leave lobby'
+ timeoutMsg: 'p3 did not leave lobby'
}
);