- Notifications
You must be signed in to change notification settings - Fork928
fix: omit login redirect param#1666
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
Don't worry about it, some router stuff is just too hard to test expect in an E2E test. We have an E2E ticket for testing redirects so you could just make sure this use case is listed there for testing. Is the util function you're using unit tested? |
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.
Not having tests for this sounds ok to me.
@presleyp yes it is! |
resolves#1282
I spent a fair amount of time attempting to write a test for this, but couldn't mock out the router in such a way that the redirect param
?redirect=%2F
reared its ugly head. Tried: using the test helpers and wrappers inrenderHelpers.tsx
, mocking logged out state similarly toLoginPage.test.tsx
, and even mocking outauthState
. Any ideas welcome.