The question asked in The Test Chat community on 14th June 2025 22:42,
Hi All,
Has anyone implemented test automation for an application that uses a magic link for login?
If yes, could you please share the approach you followed?
Thanks in advance🙏🙏
My Analysis and Understanding
- The question asked is around automation.
- That is, how to automate to use the link (hypertext) generated for login.
- There are several ways to approach this, via
- GUI
- API
- Combination of GUI and API
- I prefer to use it in combination of GUI and API for first without using any email client services and app.
- Why?
- I want to keep it simple, quick and not to complicate the testing problems much more.
Solution and Approach
I see, it is not a complicated Test Engineering problem unless the project and floor do not support.
- It should be generated somewhere within the system's boundary.
- Can you get that generated hypertext without using any mail client and its service points? How?
- Do you have an endpoint that generates this hypertext?
- If so, then this endpoint should also have some means to share the generated hypertext for login request?
- Pick this generated hypertext via an API request in your automation.
- This should work! Unless the test goal in the automation is not to open some configured mail client and read the received mail.
- But, how many times will you do this in automation, if the goal is to open configured mail client?
- Is this a good use of automation?