Skip to content

Commit

Permalink
test(e2e): fix wrong usage of store id instead of slug
Browse files Browse the repository at this point in the history
  • Loading branch information
nicotsx committed Jan 3, 2025
1 parent a73a0e4 commit b1d294f
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 7 deletions.
4 changes: 2 additions & 2 deletions e2e/0005-guest-dashboard.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ test('logged out users can see the apps on the guest dashboard', async ({ page,
throw new Error('No store found');
}

await installApp(page, store?.id, 'nginx', { visibleOnGuestDashboard: true, domain: 'duckduckgo.com' });
await installApp(page, store?.id, '2fauth', { visibleOnGuestDashboard: false });
await installApp(page, store.slug, 'nginx', { visibleOnGuestDashboard: true, domain: 'duckduckgo.com' });
await installApp(page, store.slug, '2fauth', { visibleOnGuestDashboard: false });

await page.goto('/settings');
await page.getByRole('tab', { name: 'Settings' }).click();
Expand Down
4 changes: 2 additions & 2 deletions e2e/fixtures/fixtures.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ type InstallAppOpts = {
domain?: string;
};

export const installApp = async (page: Page, storeId: number, appId: string, opts: InstallAppOpts = {}) => {
await page.goto(`/app-store/${storeId}/${appId}`);
export const installApp = async (page: Page, storeSlug: string, appId: string, opts: InstallAppOpts = {}) => {
await page.goto(`/app-store/${storeSlug}/${appId}`);

// Install app
await page.getByRole('button', { name: 'Install' }).click();
Expand Down
Original file line number Diff line number Diff line change
@@ -1,2 +1,8 @@
ALTER TABLE "app_store" ALTER COLUMN "name" SET DATA TYPE varchar(16);--> statement-breakpoint
ALTER TABLE "app_store" DROP COLUMN "deleted";
ALTER TABLE "app_store"
ALTER COLUMN "name"
SET
DATA TYPE varchar(16);

--> statement-breakpoint
ALTER TABLE "app_store"
DROP COLUMN IF EXISTS "deleted";
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
ALTER TABLE "app" ADD COLUMN "port" integer;
ALTER TABLE "app"
ADD COLUMN IF NOT EXISTS "port" integer;

0 comments on commit b1d294f

Please sign in to comment.