cal.pub0.org/apps/web/playwright/app-store.test.ts

28 lines
1.1 KiB
TypeScript
Raw Normal View History

2022-05-11 04:28:48 +00:00
import { expect } from "@playwright/test";
import { test } from "./lib/fixtures";
2022-05-11 17:12:58 +00:00
test.describe.configure({ mode: "parallel" });
test.describe("App Store - Authed", () => {
test.use({ storageState: "playwright/artifacts/proStorageState.json" });
test("Browse apple-calendar and try to install", async ({ page }) => {
await page.goto("/apps");
2022-05-11 04:28:48 +00:00
await page.click('[data-testid="app-store-category-calendar"]');
await page.click('[data-testid="app-store-app-card-apple-calendar"]');
await page.click('[data-testid="install-app-button"]');
2022-05-11 04:28:48 +00:00
await expect(page.locator(`text=Connect to Apple Server`)).toBeVisible();
});
});
test.describe("App Store - Unauthed", () => {
test("Browse apple-calendar and try to install", async ({ page }) => {
await page.goto("/apps");
2022-05-11 04:28:48 +00:00
await page.waitForSelector("[data-testid=dashboard-shell]");
await page.click('[data-testid="app-store-category-calendar"]');
await page.click('[data-testid="app-store-app-card-apple-calendar"]');
2022-05-11 03:37:09 +00:00
await page.click('[data-testid="install-app-button"]');
2022-05-11 04:28:48 +00:00
await expect(page.locator(`[data-testid="login-form"]`)).toBeVisible();
});
});