Skip to content

Commit

Permalink
fix(e2e): bring back help link tests
Browse files Browse the repository at this point in the history
  • Loading branch information
eliandoran committed Jan 17, 2025
1 parent b4ff765 commit b376f09
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 23 deletions.
27 changes: 27 additions & 0 deletions e2e/help.spec.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
import { test, expect, Page } from "@playwright/test";
import App from "./support/app";

test("Help popup", async ({ page, context }) => {
page.setDefaultTimeout(15_000);

const app = new App(page, context);
await app.goto();

const popupPromise = page.waitForEvent("popup");
await app.currentNoteSplit.press("F1");
await page.getByRole("link", { name: "online↗" }).click();
const popup = await popupPromise;
expect(popup.url()).toBe("https://triliumnext.github.io/Docs/");
});

test("Complete help in search", async ({ page, context }) => {
const app = new App(page, context);
await app.goto();

await app.launcherBar.locator(".bx-search").first().click();
await app.currentNoteSplit.locator(".search-settings .bx-help-circle").click();
const popupPromise = page.waitForEvent("popup");
await page.getByRole("link", { name: "complete help on search syntax" }).click();
const popup = await popupPromise;
expect(popup.url()).toBe("https://triliumnext.github.io/Docs/Wiki/search.html");
});
23 changes: 0 additions & 23 deletions integration-tests/help.spec.ts

This file was deleted.

0 comments on commit b376f09

Please sign in to comment.