Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
next-auth@v5-beta.16 now detects AUTH_SECRET only on server side. Needed to revamp some code accordingly
- Loading branch information
1 parent
5b073b7
commit bd7b70c
Showing
14 changed files
with
155 additions
and
62 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import { expect, test } from "./test"; | ||
|
||
test.describe("User authentication", () => { | ||
test.beforeEach(async ({ bookPage }) => { | ||
await bookPage.gotoList(); | ||
}); | ||
|
||
test("I can sign out of Admin @login", async ({ userPage, page }) => { | ||
await page.getByLabel("Profile").click(); | ||
await page.getByRole("menu").getByText("Logout").waitFor({ state: "visible" }); | ||
await page.getByRole("menu").getByText("Logout").click(); | ||
|
||
await expect(page).toHaveURL(/\/$/); | ||
|
||
// I should be logged out from Keycloak also | ||
await page.goto("/admin"); | ||
await page.waitForURL(/\/oidc\/realms\/demo\/protocol\/openid-connect\/auth/); | ||
// @ts-ignore assert declared on test.ts | ||
await expect(page).toBeOnLoginPage(); | ||
await expect(page.locator("#kc-header-wrapper")).toContainText("API Platform - Demo"); | ||
await expect(page.locator("#kc-form-login")).toContainText("Login as user: john.doe@example.com"); | ||
await expect(page.locator("#kc-form-login")).toContainText("Login as admin: chuck.norris@example.com"); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
import { AbstractPage } from "./AbstractPage"; | ||
|
||
export class UserPage extends AbstractPage { | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.