mirror of
https://github.com/getpaseo/paseo.git
synced 2026-10-25 18:52:39 +00:00
test(website): expect the plugin directory links after the announcement
PLUGINS_LINKED is now true, so the home page links /plugins from its header, footer and plugins section. The test still asserted the pre-announcement state and failed on main.
This commit is contained in:
@@ -388,19 +388,18 @@ async function expectPageMetadata(page: Page, title: string, path: string) {
|
||||
);
|
||||
}
|
||||
|
||||
test("keeps the directory unlinked until the coordinated announcement", async ({ page }) => {
|
||||
test("links the directory from the header, footer and plugins section", async ({ page }) => {
|
||||
await page.goto("/");
|
||||
await expect(
|
||||
page.getByRole("banner").getByRole("link", { name: "Plugins", exact: true }),
|
||||
).toHaveCount(0);
|
||||
page.locator("header").getByRole("link", { name: "Plugins", exact: true }),
|
||||
).toHaveAttribute("href", "/plugins");
|
||||
await expect(
|
||||
page.getByRole("contentinfo").getByRole("link", { name: "Plugins", exact: true }),
|
||||
).toHaveCount(0);
|
||||
page.locator("footer").getByRole("link", { name: "Plugins", exact: true }),
|
||||
).toHaveAttribute("href", "/plugins");
|
||||
await expect(page.getByRole("link", { name: "Browse plugins" })).toHaveAttribute(
|
||||
"href",
|
||||
"https://paseo.cafe",
|
||||
"/plugins",
|
||||
);
|
||||
await expect(page.locator('a[href="/plugins"]')).toHaveCount(0);
|
||||
const response = await page.goto("/plugins");
|
||||
expect(response?.status()).toBe(200);
|
||||
await expect(page.getByRole("heading", { level: 1, name: /^Plugins/ })).toBeVisible();
|
||||
|
||||
Reference in New Issue
Block a user