diff --git a/playwright/e2e/modules/custom-component.spec.ts b/playwright/e2e/modules/custom-component.spec.ts index 1299e7ff53..e0741f18ce 100644 --- a/playwright/e2e/modules/custom-component.spec.ts +++ b/playwright/e2e/modules/custom-component.spec.ts @@ -19,18 +19,24 @@ test.describe("Custom Component Module", () => { await use(page); }, room: async ({ page, app, user, bot }, use) => { - const roomId = await app.client.createRoom({ name: 'TestRoom' }); + const roomId = await app.client.createRoom({ name: "TestRoom" }); await use({ roomId }); }, }); - test("should replace the render method of a textual event", { tag: "@screenshot" }, async ({ page, room, app }) => { + test("should replace the render method of a textual event", { tag: "@screenshot" }, async ({ page, room, app }) => { await app.viewRoomById(room.roomId); - await app.client.sendMessage(room.roomId, 'Simple message'); + await app.client.sendMessage(room.roomId, "Simple message"); await expect(await page.getByText("Simple message")).toMatchScreenshot("custom-component-tile.png"); }); - test("should render the original content of a textual event conditionally", { tag: "@screenshot" }, async ({ page, room, app }) => { - await app.viewRoomById(room.roomId); - await app.client.sendMessage(room.roomId, 'Do not replace me'); - await expect(await page.getByText("Do not replace me")).toMatchScreenshot("custom-component-tile-original.png"); - }); + test( + "should render the original content of a textual event conditionally", + { tag: "@screenshot" }, + async ({ page, room, app }) => { + await app.viewRoomById(room.roomId); + await app.client.sendMessage(room.roomId, "Do not replace me"); + await expect(await page.getByText("Do not replace me")).toMatchScreenshot( + "custom-component-tile-original.png", + ); + }, + ); }); diff --git a/playwright/sample-files/custom-component-module.js b/playwright/sample-files/custom-component-module.js index 7ef9299c2d..14cd378838 100644 --- a/playwright/sample-files/custom-component-module.js +++ b/playwright/sample-files/custom-component-module.js @@ -15,9 +15,7 @@ export default class CustomComponentModule { return originalComponent(); } return `Custom text for ${body}`; - }) - } - async load() { - + }); } + async load() {} } diff --git a/yarn.lock b/yarn.lock index c159963cd7..0af946ad78 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3765,15 +3765,16 @@ classnames "^2.5.1" vaul "^1.0.0" -"@vector-im/matrix-wysiwyg-wasm@link:../../Library/Caches/Yarn/v6/npm-@vector-im-matrix-wysiwyg-2.38.3-cc54d8b3e9472bcd8e622126ba364ee31952cd8a-integrity/node_modules/bindings/wysiwyg-wasm": +"@vector-im/matrix-wysiwyg-wasm@link:../../../.cache/yarn/v6/npm-@vector-im-matrix-wysiwyg-2.38.3-cc54d8b3e9472bcd8e622126ba364ee31952cd8a-integrity/node_modules/bindings/wysiwyg-wasm": version "0.0.0" + uid "" "@vector-im/matrix-wysiwyg@2.38.3": version "2.38.3" resolved "https://registry.yarnpkg.com/@vector-im/matrix-wysiwyg/-/matrix-wysiwyg-2.38.3.tgz#cc54d8b3e9472bcd8e622126ba364ee31952cd8a" integrity sha512-fqo8P55Vc/t0vxpFar9RDJN5gKEjJmzrLo+O4piDbFda6VrRoqrWAtiu0Au0g6B4hRDPKIuFupk8v9Ja7q8Hvg== dependencies: - "@vector-im/matrix-wysiwyg-wasm" "link:../../Library/Caches/Yarn/v6/npm-@vector-im-matrix-wysiwyg-2.38.3-cc54d8b3e9472bcd8e622126ba364ee31952cd8a-integrity/node_modules/bindings/wysiwyg-wasm" + "@vector-im/matrix-wysiwyg-wasm" "link:../../../.cache/yarn/v6/npm-@vector-im-matrix-wysiwyg-2.38.3-cc54d8b3e9472bcd8e622126ba364ee31952cd8a-integrity/node_modules/bindings/wysiwyg-wasm" "@webassemblyjs/ast@1.14.1", "@webassemblyjs/ast@^1.14.1": version "1.14.1"