3

Consider when creating an account through an API, they are sending an email confirmation message to access the generated URL and set their password.

There is no means / method of verifying such accounts through the API itself, what is a good approach to managing this setup?

I need to create many accounts, 50-60+ over the life time of the test suite run, how can I easily validate these accounts so they are usable?

-> waiting for gmail messages using the gmail API is much too slow and a very questionable approach. -> drop the emails in some sort of drop folder?

I would prefer a non paid service solution if possible.

1 Answer 1

1

You can run mail server stub and configure the application under test to send the messages using that stub-smtp server you are running for your test. There is the number of solutions available. I prefer to use GreenMail. You can find some examples of how to assert incoming messages (and some other cases) here.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.