Fix RTE mentions autocomplete test (#28244)

LeftArrow  -> ArrowLeft
pull/28251/head
David Langley 2024-10-18 18:13:20 +01:00 committed by GitHub
parent 26430a3a6a
commit 249c0fd1df
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 5 additions and 6 deletions

View File

@ -96,8 +96,7 @@ test.describe("Composer", () => {
}, },
}); });
// https://github.com/vector-im/element-web/issues/26037 test("autocomplete behaviour tests", async ({ page, app, bot: bob }) => {
test.skip("autocomplete behaviour tests", async ({ page, app, bot: bob }) => {
// Set up a private room so we have another user to mention // Set up a private room so we have another user to mention
await app.client.createRoom({ await app.client.createRoom({
is_direct: true, is_direct: true,
@ -138,10 +137,10 @@ test.describe("Composer", () => {
.pressSequentially(`initial text @${bob.credentials.displayName.slice(0, 1)} abc`); .pressSequentially(`initial text @${bob.credentials.displayName.slice(0, 1)} abc`);
await expect(page.getByTestId("autocomplete-wrapper")).toBeEmpty(); await expect(page.getByTestId("autocomplete-wrapper")).toBeEmpty();
// Move the cursor left by 4 to put it to: `@B| abc`, check autocomplete displays // Move the cursor left by 4 to put it to: `@B| abc`, check autocomplete displays
await page.getByRole("textbox").press("LeftArrow"); await page.getByRole("textbox").press("ArrowLeft");
await page.getByRole("textbox").press("LeftArrow"); await page.getByRole("textbox").press("ArrowLeft");
await page.getByRole("textbox").press("LeftArrow"); await page.getByRole("textbox").press("ArrowLeft");
await page.getByRole("textbox").press("LeftArrow"); await page.getByRole("textbox").press("ArrowLeft");
await expect(page.getByTestId("autocomplete-wrapper")).not.toBeEmpty(); await expect(page.getByTestId("autocomplete-wrapper")).not.toBeEmpty();
// Selecting the autocomplete option using Enter inserts it into the composer // Selecting the autocomplete option using Enter inserts it into the composer