Skip to content

Scoping credentials to Firebase services #23

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

Merged
merged 3 commits into from
May 9, 2017
Merged

Conversation

hiranya911
Copy link
Contributor

No description provided.

Copy link

@wilhuff wilhuff left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM aside from a minor point on the test you added.

@@ -27,6 +27,13 @@
from tests import testutils


def check_scopes(g_credential):
assert isinstance(g_credential, google.auth.credentials.Scoped)
assert len(credentials._scopes) == len(g_credential.scopes)
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If this assertion fails you'll have a hard time figuring out what went wrong.

Better assert the lists are equal, e.g. via self.assertEqual(sorted(credentials._scopes), sorted(g_credential.scopes)).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated the test as proposed.

@wilhuff wilhuff assigned hiranya911 and unassigned wilhuff May 9, 2017
@hiranya911 hiranya911 merged commit bafd763 into master May 9, 2017
@hiranya911 hiranya911 deleted the hkj-scoped-creds branch May 9, 2017 17:53
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

Successfully merging this pull request may close these issues.

2 participants