From 71d06b4d59bc084be3a5d3c0aa88346a69ebf0b0 Mon Sep 17 00:00:00 2001 From: "mikhail.aheichyk" Date: Tue, 20 Dec 2022 11:01:14 +0300 Subject: [PATCH 1/8] Widget receives updated state events if user is re-invited into the room. --- cypress/e2e/widgets/events.spec.ts | 205 ++++++++++++++++++ .../templates/default/homeserver.yaml | 4 + src/stores/widgets/StopGapWidget.ts | 8 +- 3 files changed, 216 insertions(+), 1 deletion(-) create mode 100644 cypress/e2e/widgets/events.spec.ts diff --git a/cypress/e2e/widgets/events.spec.ts b/cypress/e2e/widgets/events.spec.ts new file mode 100644 index 0000000000..aeef1d5c76 --- /dev/null +++ b/cypress/e2e/widgets/events.spec.ts @@ -0,0 +1,205 @@ +/* +Copyright 2022 Mikhail Aheichyk +Copyright 2022 Nordeck IT + Consulting GmbH. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +/// + +import { IWidget } from "matrix-widget-api/src/interfaces/IWidget"; + +import type {MatrixClient, MatrixEvent, Room} from "matrix-js-sdk/src/matrix"; +import { SynapseInstance } from "../../plugins/synapsedocker"; +import { UserCredentials } from "../../support/login"; + +const DEMO_WIDGET_ID = "demo-widget-id"; +const DEMO_WIDGET_NAME = "Demo Widget"; +const DEMO_WIDGET_TYPE = "demo"; +const ROOM_NAME = "Demo"; + +const DEMO_WIDGET_HTML = ` + + + Demo Widget + + + + + + +`; + +function waitForRoom(win: Cypress.AUTWindow, roomId: string, predicate: (room: Room) => boolean): Promise { + const matrixClient = win.mxMatrixClientPeg.get(); + + return new Promise((resolve, reject) => { + const room = matrixClient.getRoom(roomId); + + if (predicate(room)) { + resolve(); + return; + } + + function onEvent(ev: MatrixEvent) { + if (ev.getRoomId() !== roomId) return; + + if (predicate(room)) { + matrixClient.removeListener(win.matrixcs.ClientEvent.Event, onEvent); + resolve(); + } + } + + matrixClient.on(win.matrixcs.ClientEvent.Event, onEvent); + }); +} + +describe("Widget Events", () => { + let synapse: SynapseInstance; + let user: UserCredentials; + let bot: MatrixClient; + let demoWidgetUrl: string; + + beforeEach(() => { + cy.startSynapse("default").then(data => { + synapse = data; + + cy.initTestUser(synapse, "Mike").then(_user => { + user = _user; + }); + cy.getBot(synapse, { displayName: "Bot", autoAcceptInvites: true }).then(_bot => { + bot = _bot; + }); + }); + cy.serveHtmlFile(DEMO_WIDGET_HTML).then(url => { + demoWidgetUrl = url; + }); + }); + + afterEach(() => { + cy.stopSynapse(synapse); + cy.stopWebServers(); + }); + + it('should be updated if user is re-invited into the room with updated state event', () => { + cy.createRoom({ + name: ROOM_NAME, + invite: [bot.getUserId()], + }).then(roomId => { + // setup widget via state event + cy.getClient().then(async matrixClient => { + const content: IWidget = { + id: DEMO_WIDGET_ID, + creatorUserId: 'somebody', + type: DEMO_WIDGET_TYPE, + name: DEMO_WIDGET_NAME, + url: demoWidgetUrl, + }; + await matrixClient.sendStateEvent(roomId, 'im.vector.modular.widgets', content, DEMO_WIDGET_ID); + }).as('widgetEventSent'); + + // set initial layout + cy.getClient().then(async matrixClient => { + const content = { + widgets: { + [DEMO_WIDGET_ID]: { + container: 'top', index: 1, width: 100, height: 0, + }, + }, + }; + await matrixClient.sendStateEvent(roomId, 'io.element.widgets.layout', content, ""); + }).as('layoutEventSent'); + + // open the room + cy.viewRoomByName(ROOM_NAME); + + // approve capabilities + cy.contains('.mx_WidgetCapabilitiesPromptDialog button', 'Approve').click(); + + cy.all([ + cy.get("@widgetEventSent"), + cy.get("@layoutEventSent"), + ]).then(async () => { + // bot creates a new room with 'net.metadata_invite_shared' state event + const { room_id: roomNew } = await bot.createRoom({ + name: "New room", + initial_state: [ + { + type: 'net.metadata_invite_shared', + state_key: '', + content: { + value: "initial", + }, + }, + ], + }); + + await bot.invite(roomNew, user.userId); + + // widget should receive 'net.metadata_invite_shared' event after invite + cy.window().then(async win => { + await waitForRoom(win, roomId, (room) => { + const events = room.getLiveTimeline().getEvents(); + return events.some(e => e.getType() === 'net.widget_echo' + && e.getContent().type === 'net.metadata_invite_shared' + && e.getContent().content.value === 'initial'); + }); + }); + + await bot.sendStateEvent(roomNew, 'net.metadata_invite_shared', { + value: "new_value", + }, ''); + + await bot.invite(roomNew, user.userId, 'something changed in the room'); + + // widget should receive updated 'net.metadata_invite_shared' event after re-invite + cy.window().then(async win => { + await waitForRoom(win, roomId, (room) => { + const events = room.getLiveTimeline().getEvents(); + return events.some(e => e.getType() === 'net.widget_echo' + && e.getContent().type === 'net.metadata_invite_shared' + && e.getContent().content.value === 'new_value'); + }); + }); + }); + }); + }); +}); diff --git a/cypress/plugins/synapsedocker/templates/default/homeserver.yaml b/cypress/plugins/synapsedocker/templates/default/homeserver.yaml index aaad3420b9..e282e790e9 100644 --- a/cypress/plugins/synapsedocker/templates/default/homeserver.yaml +++ b/cypress/plugins/synapsedocker/templates/default/homeserver.yaml @@ -74,3 +74,7 @@ suppress_key_server_warning: true ui_auth: session_timeout: "300s" + +room_prejoin_state: + additional_event_types: + - net.metadata_invite_shared diff --git a/src/stores/widgets/StopGapWidget.ts b/src/stores/widgets/StopGapWidget.ts index 9230dda12e..f7586e86ec 100644 --- a/src/stores/widgets/StopGapWidget.ts +++ b/src/stores/widgets/StopGapWidget.ts @@ -520,7 +520,13 @@ export class StopGapWidget extends EventEmitter { } } - this.readUpToMap[ev.getRoomId()] = ev.getId(); + // Skip marker assignment if membership is 'invite', otherwise 'm.room.member' from + // invitation room will assign it and new state events will be not forwarded to the widget + // because of empty timeline for invitation room and assigned marker. + const room = this.client.getRoom(ev.getRoomId()); + if (room && room.getMyMembership() !== 'invite') { + this.readUpToMap[ev.getRoomId()] = ev.getId(); + } const raw = ev.getEffectiveEvent(); this.messaging.feedEvent(raw as IRoomEvent, this.eventListenerRoomId).catch((e) => { From e0b6e52d9c0d1faca8a96ee709c508c6cc158367 Mon Sep 17 00:00:00 2001 From: "mikhail.aheichyk" Date: Tue, 20 Dec 2022 12:20:40 +0300 Subject: [PATCH 2/8] prettier --- cypress/e2e/widgets/events.spec.ts | 105 ++++++++++-------- .../templates/default/homeserver.yaml | 4 +- src/stores/widgets/StopGapWidget.ts | 2 +- 3 files changed, 63 insertions(+), 48 deletions(-) diff --git a/cypress/e2e/widgets/events.spec.ts b/cypress/e2e/widgets/events.spec.ts index aeef1d5c76..f5ebf0397e 100644 --- a/cypress/e2e/widgets/events.spec.ts +++ b/cypress/e2e/widgets/events.spec.ts @@ -19,7 +19,7 @@ limitations under the License. import { IWidget } from "matrix-widget-api/src/interfaces/IWidget"; -import type {MatrixClient, MatrixEvent, Room} from "matrix-js-sdk/src/matrix"; +import type { MatrixClient, MatrixEvent, Room } from "matrix-js-sdk/src/matrix"; import { SynapseInstance } from "../../plugins/synapsedocker"; import { UserCredentials } from "../../support/login"; @@ -99,17 +99,17 @@ describe("Widget Events", () => { let demoWidgetUrl: string; beforeEach(() => { - cy.startSynapse("default").then(data => { + cy.startSynapse("default").then((data) => { synapse = data; - cy.initTestUser(synapse, "Mike").then(_user => { + cy.initTestUser(synapse, "Mike").then((_user) => { user = _user; }); - cy.getBot(synapse, { displayName: "Bot", autoAcceptInvites: true }).then(_bot => { + cy.getBot(synapse, { displayName: "Bot", autoAcceptInvites: true }).then((_bot) => { bot = _bot; }); }); - cy.serveHtmlFile(DEMO_WIDGET_HTML).then(url => { + cy.serveHtmlFile(DEMO_WIDGET_HTML).then((url) => { demoWidgetUrl = url; }); }); @@ -119,52 +119,56 @@ describe("Widget Events", () => { cy.stopWebServers(); }); - it('should be updated if user is re-invited into the room with updated state event', () => { + it("should be updated if user is re-invited into the room with updated state event", () => { cy.createRoom({ name: ROOM_NAME, invite: [bot.getUserId()], - }).then(roomId => { + }).then((roomId) => { // setup widget via state event - cy.getClient().then(async matrixClient => { - const content: IWidget = { - id: DEMO_WIDGET_ID, - creatorUserId: 'somebody', - type: DEMO_WIDGET_TYPE, - name: DEMO_WIDGET_NAME, - url: demoWidgetUrl, - }; - await matrixClient.sendStateEvent(roomId, 'im.vector.modular.widgets', content, DEMO_WIDGET_ID); - }).as('widgetEventSent'); + cy.getClient() + .then(async (matrixClient) => { + const content: IWidget = { + id: DEMO_WIDGET_ID, + creatorUserId: "somebody", + type: DEMO_WIDGET_TYPE, + name: DEMO_WIDGET_NAME, + url: demoWidgetUrl, + }; + await matrixClient.sendStateEvent(roomId, "im.vector.modular.widgets", content, DEMO_WIDGET_ID); + }) + .as("widgetEventSent"); // set initial layout - cy.getClient().then(async matrixClient => { - const content = { - widgets: { - [DEMO_WIDGET_ID]: { - container: 'top', index: 1, width: 100, height: 0, + cy.getClient() + .then(async (matrixClient) => { + const content = { + widgets: { + [DEMO_WIDGET_ID]: { + container: "top", + index: 1, + width: 100, + height: 0, + }, }, - }, - }; - await matrixClient.sendStateEvent(roomId, 'io.element.widgets.layout', content, ""); - }).as('layoutEventSent'); + }; + await matrixClient.sendStateEvent(roomId, "io.element.widgets.layout", content, ""); + }) + .as("layoutEventSent"); // open the room cy.viewRoomByName(ROOM_NAME); // approve capabilities - cy.contains('.mx_WidgetCapabilitiesPromptDialog button', 'Approve').click(); + cy.contains(".mx_WidgetCapabilitiesPromptDialog button", "Approve").click(); - cy.all([ - cy.get("@widgetEventSent"), - cy.get("@layoutEventSent"), - ]).then(async () => { + cy.all([cy.get("@widgetEventSent"), cy.get("@layoutEventSent")]).then(async () => { // bot creates a new room with 'net.metadata_invite_shared' state event const { room_id: roomNew } = await bot.createRoom({ name: "New room", initial_state: [ { - type: 'net.metadata_invite_shared', - state_key: '', + type: "net.metadata_invite_shared", + state_key: "", content: { value: "initial", }, @@ -175,28 +179,39 @@ describe("Widget Events", () => { await bot.invite(roomNew, user.userId); // widget should receive 'net.metadata_invite_shared' event after invite - cy.window().then(async win => { + cy.window().then(async (win) => { await waitForRoom(win, roomId, (room) => { const events = room.getLiveTimeline().getEvents(); - return events.some(e => e.getType() === 'net.widget_echo' - && e.getContent().type === 'net.metadata_invite_shared' - && e.getContent().content.value === 'initial'); + return events.some( + (e) => + e.getType() === "net.widget_echo" && + e.getContent().type === "net.metadata_invite_shared" && + e.getContent().content.value === "initial", + ); }); }); - await bot.sendStateEvent(roomNew, 'net.metadata_invite_shared', { - value: "new_value", - }, ''); + await bot.sendStateEvent( + roomNew, + "net.metadata_invite_shared", + { + value: "new_value", + }, + "", + ); - await bot.invite(roomNew, user.userId, 'something changed in the room'); + await bot.invite(roomNew, user.userId, "something changed in the room"); // widget should receive updated 'net.metadata_invite_shared' event after re-invite - cy.window().then(async win => { + cy.window().then(async (win) => { await waitForRoom(win, roomId, (room) => { const events = room.getLiveTimeline().getEvents(); - return events.some(e => e.getType() === 'net.widget_echo' - && e.getContent().type === 'net.metadata_invite_shared' - && e.getContent().content.value === 'new_value'); + return events.some( + (e) => + e.getType() === "net.widget_echo" && + e.getContent().type === "net.metadata_invite_shared" && + e.getContent().content.value === "new_value", + ); }); }); }); diff --git a/cypress/plugins/synapsedocker/templates/default/homeserver.yaml b/cypress/plugins/synapsedocker/templates/default/homeserver.yaml index e282e790e9..f35f5a55e6 100644 --- a/cypress/plugins/synapsedocker/templates/default/homeserver.yaml +++ b/cypress/plugins/synapsedocker/templates/default/homeserver.yaml @@ -76,5 +76,5 @@ ui_auth: session_timeout: "300s" room_prejoin_state: - additional_event_types: - - net.metadata_invite_shared + additional_event_types: + - net.metadata_invite_shared diff --git a/src/stores/widgets/StopGapWidget.ts b/src/stores/widgets/StopGapWidget.ts index f7586e86ec..9efa14829c 100644 --- a/src/stores/widgets/StopGapWidget.ts +++ b/src/stores/widgets/StopGapWidget.ts @@ -524,7 +524,7 @@ export class StopGapWidget extends EventEmitter { // invitation room will assign it and new state events will be not forwarded to the widget // because of empty timeline for invitation room and assigned marker. const room = this.client.getRoom(ev.getRoomId()); - if (room && room.getMyMembership() !== 'invite') { + if (room && room.getMyMembership() !== "invite") { this.readUpToMap[ev.getRoomId()] = ev.getId(); } From 7f0621e84da1965076a8ad14fe76777abc8b5ce9 Mon Sep 17 00:00:00 2001 From: "mikhail.aheichyk" Date: Tue, 20 Dec 2022 12:52:31 +0300 Subject: [PATCH 3/8] ts error fix --- src/stores/widgets/StopGapWidget.ts | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/stores/widgets/StopGapWidget.ts b/src/stores/widgets/StopGapWidget.ts index 9efa14829c..dfacefa1cd 100644 --- a/src/stores/widgets/StopGapWidget.ts +++ b/src/stores/widgets/StopGapWidget.ts @@ -523,9 +523,11 @@ export class StopGapWidget extends EventEmitter { // Skip marker assignment if membership is 'invite', otherwise 'm.room.member' from // invitation room will assign it and new state events will be not forwarded to the widget // because of empty timeline for invitation room and assigned marker. - const room = this.client.getRoom(ev.getRoomId()); - if (room && room.getMyMembership() !== "invite") { - this.readUpToMap[ev.getRoomId()] = ev.getId(); + if (ev.getRoomId()) { + const room = this.client.getRoom(ev.getRoomId()); + if (room && room.getMyMembership() !== "invite") { + this.readUpToMap[ev.getRoomId()] = ev.getId(); + } } const raw = ev.getEffectiveEvent(); From f1f61cb40d3570f1cddc649d28541c3f7fe5e52f Mon Sep 17 00:00:00 2001 From: "mikhail.aheichyk" Date: Tue, 20 Dec 2022 13:41:13 +0300 Subject: [PATCH 4/8] ts error fix --- src/stores/widgets/StopGapWidget.ts | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/stores/widgets/StopGapWidget.ts b/src/stores/widgets/StopGapWidget.ts index dfacefa1cd..433d681b02 100644 --- a/src/stores/widgets/StopGapWidget.ts +++ b/src/stores/widgets/StopGapWidget.ts @@ -523,10 +523,12 @@ export class StopGapWidget extends EventEmitter { // Skip marker assignment if membership is 'invite', otherwise 'm.room.member' from // invitation room will assign it and new state events will be not forwarded to the widget // because of empty timeline for invitation room and assigned marker. - if (ev.getRoomId()) { - const room = this.client.getRoom(ev.getRoomId()); + const evRoomId = ev.getRoomId(); + const evId = ev.getId(); + if (evRoomId && evId) { + const room = this.client.getRoom(evRoomId); if (room && room.getMyMembership() !== "invite") { - this.readUpToMap[ev.getRoomId()] = ev.getId(); + this.readUpToMap[evRoomId] = evId; } } From 0d7152a8d9e5ab0c25b22766b5e87f150a76356a Mon Sep 17 00:00:00 2001 From: Mikhail Aheichyk Date: Thu, 12 Jan 2023 12:49:24 +0300 Subject: [PATCH 5/8] update the test after merge --- cypress/e2e/widgets/events.spec.ts | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/cypress/e2e/widgets/events.spec.ts b/cypress/e2e/widgets/events.spec.ts index f5ebf0397e..daf8e449ba 100644 --- a/cypress/e2e/widgets/events.spec.ts +++ b/cypress/e2e/widgets/events.spec.ts @@ -20,7 +20,7 @@ limitations under the License. import { IWidget } from "matrix-widget-api/src/interfaces/IWidget"; import type { MatrixClient, MatrixEvent, Room } from "matrix-js-sdk/src/matrix"; -import { SynapseInstance } from "../../plugins/synapsedocker"; +import { HomeserverInstance } from "../../plugins/utils/homeserver"; import { UserCredentials } from "../../support/login"; const DEMO_WIDGET_ID = "demo-widget-id"; @@ -93,19 +93,19 @@ function waitForRoom(win: Cypress.AUTWindow, roomId: string, predicate: (room: R } describe("Widget Events", () => { - let synapse: SynapseInstance; + let homeserver: HomeserverInstance; let user: UserCredentials; let bot: MatrixClient; let demoWidgetUrl: string; beforeEach(() => { - cy.startSynapse("default").then((data) => { - synapse = data; + cy.startHomeserver("default").then((data) => { + homeserver = data; - cy.initTestUser(synapse, "Mike").then((_user) => { + cy.initTestUser(homeserver, "Mike").then((_user) => { user = _user; }); - cy.getBot(synapse, { displayName: "Bot", autoAcceptInvites: true }).then((_bot) => { + cy.getBot(homeserver, { displayName: "Bot", autoAcceptInvites: true }).then((_bot) => { bot = _bot; }); }); @@ -115,7 +115,7 @@ describe("Widget Events", () => { }); afterEach(() => { - cy.stopSynapse(synapse); + cy.stopHomeserver(homeserver); cy.stopWebServers(); }); From 4f68742076795def0fc55129f0edb4864efe3253 Mon Sep 17 00:00:00 2001 From: Mikhail Aheichyk Date: Thu, 12 Jan 2023 14:37:23 +0300 Subject: [PATCH 6/8] excluded 'leave' membership to fix the issue that events are not received by widget after re-invite --- src/stores/widgets/StopGapWidget.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/stores/widgets/StopGapWidget.ts b/src/stores/widgets/StopGapWidget.ts index 4e12e6f8cf..9fab6e66ee 100644 --- a/src/stores/widgets/StopGapWidget.ts +++ b/src/stores/widgets/StopGapWidget.ts @@ -526,7 +526,7 @@ export class StopGapWidget extends EventEmitter { const evId = ev.getId(); if (evRoomId && evId) { const room = this.client.getRoom(evRoomId); - if (room && room.getMyMembership() !== "invite") { + if (room && room.getMyMembership() === "join") { this.readUpToMap[evRoomId] = evId; } } From b3472753dc9d661acf1def4f3b587cc3cc9b50d1 Mon Sep 17 00:00:00 2001 From: Mikhail Aheichyk Date: Fri, 13 Jan 2023 14:53:06 +0300 Subject: [PATCH 7/8] events.spec.ts is changed to use 'm.room.topic' instead of custom event --- cypress/e2e/widgets/events.spec.ts | 25 ++++++++++--------- .../templates/default/homeserver.yaml | 4 --- 2 files changed, 13 insertions(+), 16 deletions(-) diff --git a/cypress/e2e/widgets/events.spec.ts b/cypress/e2e/widgets/events.spec.ts index daf8e449ba..ec47205759 100644 --- a/cypress/e2e/widgets/events.spec.ts +++ b/cypress/e2e/widgets/events.spec.ts @@ -40,7 +40,7 @@ const DEMO_WIDGET_HTML = ` response: { capabilities: [ "org.matrix.msc2762.timeline:*", - "org.matrix.msc2762.receive.state_event:net.metadata_invite_shared", + "org.matrix.msc2762.receive.state_event:m.room.topic", "org.matrix.msc2762.send.event:net.widget_echo" ] }, @@ -162,15 +162,15 @@ describe("Widget Events", () => { cy.contains(".mx_WidgetCapabilitiesPromptDialog button", "Approve").click(); cy.all([cy.get("@widgetEventSent"), cy.get("@layoutEventSent")]).then(async () => { - // bot creates a new room with 'net.metadata_invite_shared' state event + // bot creates a new room with 'm.room.topic' const { room_id: roomNew } = await bot.createRoom({ name: "New room", initial_state: [ { - type: "net.metadata_invite_shared", + type: "m.room.topic", state_key: "", content: { - value: "initial", + topic: "topic initial", }, }, ], @@ -178,39 +178,40 @@ describe("Widget Events", () => { await bot.invite(roomNew, user.userId); - // widget should receive 'net.metadata_invite_shared' event after invite + // widget should receive 'm.room.topic' event after invite cy.window().then(async (win) => { await waitForRoom(win, roomId, (room) => { const events = room.getLiveTimeline().getEvents(); return events.some( (e) => e.getType() === "net.widget_echo" && - e.getContent().type === "net.metadata_invite_shared" && - e.getContent().content.value === "initial", + e.getContent().type === "m.room.topic" && + e.getContent().content.topic === "topic initial", ); }); }); + // update the topic await bot.sendStateEvent( roomNew, - "net.metadata_invite_shared", + "m.room.topic", { - value: "new_value", + topic: "topic updated", }, "", ); await bot.invite(roomNew, user.userId, "something changed in the room"); - // widget should receive updated 'net.metadata_invite_shared' event after re-invite + // widget should receive updated 'net.room.topic' event after re-invite cy.window().then(async (win) => { await waitForRoom(win, roomId, (room) => { const events = room.getLiveTimeline().getEvents(); return events.some( (e) => e.getType() === "net.widget_echo" && - e.getContent().type === "net.metadata_invite_shared" && - e.getContent().content.value === "new_value", + e.getContent().type === "m.room.topic" && + e.getContent().content.topic === "topic updated", ); }); }); diff --git a/cypress/plugins/synapsedocker/templates/default/homeserver.yaml b/cypress/plugins/synapsedocker/templates/default/homeserver.yaml index f35f5a55e6..aaad3420b9 100644 --- a/cypress/plugins/synapsedocker/templates/default/homeserver.yaml +++ b/cypress/plugins/synapsedocker/templates/default/homeserver.yaml @@ -74,7 +74,3 @@ suppress_key_server_warning: true ui_auth: session_timeout: "300s" - -room_prejoin_state: - additional_event_types: - - net.metadata_invite_shared From 097d7fb5ebe8cac9ecfc8831bb2b9f80677341b3 Mon Sep 17 00:00:00 2001 From: Mikhail Aheichyk Date: Mon, 16 Jan 2023 11:30:29 +0300 Subject: [PATCH 8/8] Comment fixed --- cypress/e2e/widgets/events.spec.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cypress/e2e/widgets/events.spec.ts b/cypress/e2e/widgets/events.spec.ts index ec47205759..d9aeb46062 100644 --- a/cypress/e2e/widgets/events.spec.ts +++ b/cypress/e2e/widgets/events.spec.ts @@ -203,7 +203,7 @@ describe("Widget Events", () => { await bot.invite(roomNew, user.userId, "something changed in the room"); - // widget should receive updated 'net.room.topic' event after re-invite + // widget should receive updated 'm.room.topic' event after re-invite cy.window().then(async (win) => { await waitForRoom(win, roomId, (room) => { const events = room.getLiveTimeline().getEvents();