Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OAuth emulator testing does not work. #992

Open
marcusx2 opened this issue Sep 19, 2023 · 0 comments
Open

OAuth emulator testing does not work. #992

marcusx2 opened this issue Sep 19, 2023 · 0 comments

Comments

@marcusx2
Copy link

Describe the bug

The documentation says that I can mock signing in different users. While it works when using the GoogleAuthProvider, it doesn't work when using the OAuthProvider, even though the documentation states

You can replace firebase.auth.GoogleAuthProvider with, for example, new firebase.auth.OAuthProvider('yahoo.com') or any other provider ID you want to mock.

To Reproduce

var provider = new OAuthProvider("google.com");
var credential = provider.credential("{\"sub\": \"abc123\", \"email\": \"foo@example.com\", \"email_verified\": true}");

You will get the following error FirebaseError: Firebase: Error (auth/argument-error).

Expected behavior

It should work as described in the docs..

Desktop (please complete the following information):

  • OS: macOS
  • Browser Safari
  • Version 16.5.2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant