2025 / apps /web /tests /home.spec.ts
daqc's picture
Initial commit
ad19202
import { expect, test } from "@playwright/test";
import { config } from "@repo/config";
test.describe("home page", () => {
if (config.ui.marketing.enabled) {
test("should load", async ({ page }) => {
await page.goto("/");
await expect(
page.getByRole("heading", {
name: "Your year on Hugging Face, instantly",
}),
).toBeVisible();
});
} else {
test("should be redirected to app", async ({ page }) => {
await page.goto("/");
await expect(page).toHaveURL(/\.*\/auth\/login/);
});
}
});