feat: move routes to slugs

This commit is contained in:
2026-09-27 16:35:27 +05:00
parent 9776e1d325
commit d09c954694
8 changed files with 25 additions and 26 deletions
+4 -4
View File
@@ -31,14 +31,14 @@ export async function useEnglish(page: Page): Promise<void> {
});
}
export async function openTool(page: Page, id: string): Promise<void> {
export async function openTool(page: Page, slug: string): Promise<void> {
await useEnglish(page);
await page.goto(`/tools/${id}`);
await page.goto(`/tools/${slug}`);
await expect(page.getByRole("heading", { level: 1 })).toBeVisible();
}
export function toolLink(page: Page, id: string): Locator {
return page.locator(`a[href="/tools/${id}"]`);
export function toolLink(page: Page, slug: string): Locator {
return page.locator(`a[href="/tools/${slug}"]`);
}
export function resultImage(page: Page): Locator {