This commit is contained in:
Anthony Stirling 2025-12-15 23:34:28 +00:00
parent 9ea2c94912
commit 43137cde83
2 changed files with 5 additions and 5 deletions

View File

@ -343,7 +343,7 @@ describe('SpringAuthClient', () => {
});
const result = await springAuth.signInWithOAuth({
provider: 'github',
provider: '/oauth2/authorization/github',
options: { redirectTo: '/auth/callback' },
});

View File

@ -295,9 +295,9 @@ describe('Login', () => {
await user.click(oauthButton);
await waitFor(() => {
// Should use 'authentik' directly, NOT map to 'oidc'
// Should use full path directly, NOT map to 'oidc'
expect(springAuth.signInWithOAuth).toHaveBeenCalledWith({
provider: 'authentik',
provider: '/oauth2/authorization/authentik',
options: { redirectTo: '/auth/callback' }
});
});
@ -338,10 +338,10 @@ describe('Login', () => {
await user.click(oauthButton);
await waitFor(() => {
// Should use 'mycompany' directly - this is the critical fix
// Should use full path directly - this is the critical fix
// Previously it would map unknown providers to 'oidc'
expect(springAuth.signInWithOAuth).toHaveBeenCalledWith({
provider: 'mycompany',
provider: '/oauth2/authorization/mycompany',
options: { redirectTo: '/auth/callback' }
});
});