-
Notifications
You must be signed in to change notification settings - Fork 88
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
(DOCSP-33539): React Native: Update Create & Manage User API Keys to use auth hooks #3180
Conversation
- Final step of test is failing due to weird network errors. Works when using app manually.
Currently getting the following error or one about no refresh token on the last bit of the test.
This only happens in the Jest test. Everything works in the simulator. Trying to figure it out. |
✅ Deploy Preview for device-sdk ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
Readability for Commit Hash: fdda3b4 You can see any previous Readability scores (if they exist) by looking Readability scores for changed documents:
For Grade Level, aim for 8 or below. For Reading Ease scores, aim for 60 or above:
For help improving readability, try Hemingway App. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the new approach re: the steps is clever! But I don't love that this creates a dependency chain from step N to step N. We have been trying to move to making our tests more separated, and eliminate inter-dependencies - so it seems like this is moving in the opposite direction. Maybe we could talk offline about this shift in approach?
client accessed with an authenticated user's :js-sdk:`User.apiKeys | ||
<Realm.User.html#apiKeys>` property. | ||
<classes/Realm.User.html#apiKeys>` property. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think I would like to see a heading between this intro bit and the @realm/react
info. It would be nice to have this as a scannable heading in the OTP. i.e. something like:
API Key Auth with @realm/react
Or:
React Hooks
Or something that indicates this is the info about how to use this with hooks.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That makes sense. Thank you for pointing this out!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Dachary has reviewed and approved, but since this was originally her PR, she can't approve it on GitHub. So, I'm approving in her place. 😄
✨ Staging URL: https://preview-mongodbmongodb.gatsbyjs.io/realm/master/ 🪵 Logs |
Pull Request Info
Jira ticket: https://jira.mongodb.org/browse/DOCSP-33539
This PR adds to the React Native test suite, enabling us to test API user auth in a more robust way. The React Native tests in general are still somewhat flaky in CI - some of them are failing the CI for this PR but pass locally. These are mostly related to tests that make network requests. The pattern established in this PR should help address network issues and make tests more reliable in CI.
Essentially, the test is more an integration test than a unit test. I recommend we go to this higher-level testing for most networking aspects for examples that integrate with UI elements.
Reminder Checklist
Before merging your PR, make sure to check a few things.
Release Notes
Review Guidelines
REVIEWING.md