Skip to content

Commit 3f25439

Browse files
fix(test): accept /account/login as valid hosted-login redirect in real e2e
1 parent f6d92b3 commit 3f25439

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

packages/nextjs/tests/e2e/real/smoke.spec.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,9 @@ test.describe('real-tenant smoke', () => {
1111
await page.goto('/', { waitUntil: 'domcontentloaded' });
1212
const finalUrl = page.url();
1313
const baseUrl = process.env.FRONTEGG_BASE_URL!;
14-
const redirectedToOAuth = finalUrl.includes(new URL(baseUrl).host) || finalUrl.includes('/oauth/');
15-
expect(redirectedToOAuth, `expected OAuth redirect, got ${finalUrl}`).toBe(true);
14+
const redirectedToLogin =
15+
finalUrl.includes(new URL(baseUrl).host) || finalUrl.includes('/oauth/') || finalUrl.includes('/account/login');
16+
expect(redirectedToLogin, `expected login redirect, got ${finalUrl}`).toBe(true);
1617
});
1718

1819
test('public no-ssr endpoint renders without a session', async ({ page }) => {

0 commit comments

Comments
 (0)