You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
How to efficiently e2e test while having e-mail sign-in as the only enabled authentication provider?
What are you trying to do
I have an application that I would like to write e2e tests for using CodeceptJS. As mentioned in my question, my only authentication provider is e-mail sign-in. Most of my application functionalities are locked behind being logged in by the user. I also know that CodeceptJS has a very nice abstraction for e-mails using MailSlurp which I have already configured and tried out. The only problem with using actual e-mails in tests is that temporary mailboxes and e-mails are too expensive for this to be an option.
Is there any other way to write tests like these efficiently or is the only option just actually sending, opening the e-mail and clicking the link? If there isn't any other way - would you be interested if I prepared a pull request with an implementation of a feature that allows for skipping the e-mail sending process and just returns the relevant cookie when /signin route is called?
Found the documentation helpful
Found documentation but was incomplete
Could not find relevant documentation
Found the example project helpful
Did not find the example project helpful
Edit: Sorry if I should have posted this in GitHub discussions, I thought that it will get converted automatically 🤔
This discussion was converted from issue #1548 on March 19, 2021 18:23.
Heading
Bold
Italic
Quote
Code
Link
Numbered list
Unordered list
Task list
Attach files
Mention
Reference
Menu
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Your question
How to efficiently e2e test while having e-mail sign-in as the only enabled authentication provider?
What are you trying to do
I have an application that I would like to write e2e tests for using CodeceptJS. As mentioned in my question, my only authentication provider is e-mail sign-in. Most of my application functionalities are locked behind being logged in by the user. I also know that CodeceptJS has a very nice abstraction for e-mails using MailSlurp which I have already configured and tried out. The only problem with using actual e-mails in tests is that temporary mailboxes and e-mails are too expensive for this to be an option.
Is there any other way to write tests like these efficiently or is the only option just actually sending, opening the e-mail and clicking the link? If there isn't any other way - would you be interested if I prepared a pull request with an implementation of a feature that allows for skipping the e-mail sending process and just returns the relevant cookie when
/signin
route is called?Edit: Sorry if I should have posted this in GitHub discussions, I thought that it will get converted automatically 🤔
Beta Was this translation helpful? Give feedback.
All reactions