V2 App Store test fixes
parent
a9b41766f2
commit
8da31cb293
|
@ -8,8 +8,7 @@ test.describe("App Store - Authed", () => {
|
||||||
test("Browse apple-calendar and try to install", async ({ page, users }) => {
|
test("Browse apple-calendar and try to install", async ({ page, users }) => {
|
||||||
const pro = await users.create();
|
const pro = await users.create();
|
||||||
await pro.login();
|
await pro.login();
|
||||||
await page.goto("/apps");
|
await page.goto("/apps/categories/calendar");
|
||||||
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="app-store-app-card-apple-calendar"]');
|
||||||
await page.click('[data-testid="install-app-button"]');
|
await page.click('[data-testid="install-app-button"]');
|
||||||
await expect(page.locator(`text=Connect to Apple Server`)).toBeVisible();
|
await expect(page.locator(`text=Connect to Apple Server`)).toBeVisible();
|
||||||
|
@ -19,9 +18,7 @@ test.describe("App Store - Authed", () => {
|
||||||
|
|
||||||
test.describe("App Store - Unauthed", () => {
|
test.describe("App Store - Unauthed", () => {
|
||||||
test("Browse apple-calendar and try to install", async ({ page }) => {
|
test("Browse apple-calendar and try to install", async ({ page }) => {
|
||||||
await page.goto("/apps");
|
await page.goto("/apps/categories/calendar");
|
||||||
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"]');
|
await page.click('[data-testid="app-store-app-card-apple-calendar"]');
|
||||||
await page.click('[data-testid="install-app-button"]');
|
await page.click('[data-testid="install-app-button"]');
|
||||||
await expect(page.locator(`[data-testid="login-form"]`)).toBeVisible();
|
await expect(page.locator(`[data-testid="login-form"]`)).toBeVisible();
|
||||||
|
|
|
@ -30,9 +30,7 @@ export default function AppCard({ app, credentials }: AppCardProps) {
|
||||||
const appAdded = (credentials && credentials.length) || 0;
|
const appAdded = (credentials && credentials.length) || 0;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div
|
<div className="relative flex h-64 flex-col rounded-md border border-gray-300 p-5">
|
||||||
className="relative flex h-64 flex-col rounded-md border border-gray-300 p-5"
|
|
||||||
data-testid={`app-store-app-card-${app.slug}`}>
|
|
||||||
<div className="flex">
|
<div className="flex">
|
||||||
<img src={app.logo} alt={app.name + " Logo"} className="mb-4 h-12 w-12 rounded-sm" />
|
<img src={app.logo} alt={app.name + " Logo"} className="mb-4 h-12 w-12 rounded-sm" />
|
||||||
</div>
|
</div>
|
||||||
|
@ -54,7 +52,11 @@ export default function AppCard({ app, credentials }: AppCardProps) {
|
||||||
{app.description}
|
{app.description}
|
||||||
</p>
|
</p>
|
||||||
<div className="mt-5 flex max-w-full flex-row flex-wrap justify-between gap-2">
|
<div className="mt-5 flex max-w-full flex-row flex-wrap justify-between gap-2">
|
||||||
<Button color="secondary" className="flex w-32 flex-grow justify-center" href={"/apps/" + app.slug}>
|
<Button
|
||||||
|
color="secondary"
|
||||||
|
className="flex w-32 flex-grow justify-center"
|
||||||
|
href={`/apps/${app.slug}`}
|
||||||
|
data-testid={`app-store-app-card-${app.slug}`}>
|
||||||
{t("details")}
|
{t("details")}
|
||||||
</Button>
|
</Button>
|
||||||
{app.isGlobal || (credentials && credentials.length > 0 && allowedMultipleInstalls)
|
{app.isGlobal || (credentials && credentials.length > 0 && allowedMultipleInstalls)
|
||||||
|
|
Loading…
Reference in New Issue