From 5297be9a15db5eb18c38a8d9c1fb8d3fff1558fe Mon Sep 17 00:00:00 2001 From: McKayla Washburn Date: Fri, 6 Dec 2024 14:37:58 -0700 Subject: [PATCH] chore: improve e2e organization test --- site/e2e/tests/organizations.spec.ts | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/site/e2e/tests/organizations.spec.ts b/site/e2e/tests/organizations.spec.ts index a0cc6089c48d2..625eac4762997 100644 --- a/site/e2e/tests/organizations.spec.ts +++ b/site/e2e/tests/organizations.spec.ts @@ -17,20 +17,27 @@ test("create and delete organization", async ({ page }) => { waitUntil: "domcontentloaded", }); - await page.getByLabel("Slug", { exact: true }).fill("floop"); + await page.getByLabel("Slug").fill("floop"); await page.getByLabel("Display name").fill("Floop"); await page.getByLabel("Description").fill("Org description floop"); await page.getByLabel("Icon", { exact: true }).fill("/emojis/1f957.png"); - await page.getByRole("button", { name: "Submit" }).click(); // Expect to be redirected to the new organization await expectUrl(page).toHavePathName("/organizations/floop"); await expect(page.getByText("Organization created.")).toBeVisible(); + await page.getByLabel("Slug").fill("wibble"); + await page.getByLabel("Description").fill("Org description wibble"); + await page.getByRole("button", { name: "Submit" }).click(); + + // Expect to be redirected when renaming the organization + await expectUrl(page).toHavePathName("/organizations/wibble"); + await expect(page.getByText("Organization settings updated.")).toBeVisible(); + await page.getByRole("button", { name: "Delete this organization" }).click(); const dialog = page.getByTestId("dialog"); - await dialog.getByLabel("Name").fill("floop"); + await dialog.getByLabel("Name").fill("wibble"); await dialog.getByRole("button", { name: "Delete" }).click(); await expect(page.getByText("Organization deleted.")).toBeVisible(); }); pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy