Skip to content

Commit

Permalink
change the room joined position
Browse files Browse the repository at this point in the history
  • Loading branch information
iAmmar7 committed Jan 20, 2025
1 parent aea4f99 commit 834c78c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
10 changes: 5 additions & 5 deletions internal/e2e-js/tests/roomSessionDemotePromote.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,11 @@ test.describe('RoomSession demote participant and then promote again', () => {

await pageTwo.waitForTimeout(1000)

// --------------- Promote audience from pageOne and resolve on `member.joined` ---------------
// --------------- Promote audience from pageOne and resolve on `member.joined` and `room.joined` ---------------
const promisePromotedRoomJoined = expectRoomJoined(pageTwo, {
invokeJoin: false,
})

const promiseMemberWaitingForMemberJoin = pageOne.evaluate(
async ({ promoteMemberId }) => {
// @ts-expect-error
Expand Down Expand Up @@ -170,10 +174,6 @@ test.describe('RoomSession demote participant and then promote again', () => {
{ promoteMemberId: participant2Id }
)

const promisePromotedRoomJoined = expectRoomJoined(pageTwo, {
invokeJoin: false,
})

await Promise.all([
promiseMemberWaitingForMemberJoin,
promisePromotedRoomJoined,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,10 @@ test.describe('RoomSession demote participant, reattach and then promote again',

// --------------- Time to promote again at PageTwo ---------------

const promisePromotedRoomJoined = expectRoomJoined(pageTwo, {
invokeJoin: false,
})

const promiseMemberWaitingForMemberJoin = pageOne.evaluate(
async ({ promoteMemberId }) => {
// @ts-expect-error
Expand Down Expand Up @@ -202,10 +206,6 @@ test.describe('RoomSession demote participant, reattach and then promote again',
{ promoteMemberId: participant2Id }
)

const promisePromotedRoomJoined = expectRoomJoined(pageTwo, {
invokeJoin: false,
})

await Promise.all([
promiseMemberWaitingForMemberJoin,
promisePromotedRoomJoined,
Expand Down

0 comments on commit 834c78c

Please sign in to comment.