Videos
Check out our tutorial video series.
Using disposable emails with Cypress JS when application testing. MailSlurp allows us to create custom inboxes on demand and use them during automated tests.
MailSlurp is a free Javascript plugin for Cypress JS that lets you create real email addresses in tests then send and receive emails from them. This can be really helpful when testing applications or software. Cypress can be used to test user login and app notifications using real email addresses and phone numbers.
Cypress is a browser testing tool that lets you automate end-to-end testing of your website. You can write test cases in Javascript using the Cypress NPM package. Make assertions about the state of a website or app and Cypress will run the tests in a browser environment for real browser testing.
Cypress has many abilities so try one of these links to get started:
Many applications today use email. Either for user sign-up, password verification, transactional email, newsletters, and more.
But testing with real email addresses is hard. That's why MailSlurp was created. It lets you generate test email accounts that can send and receive emails. It has an official NPM integration and works well with Cypress async.
We write Cypress tests in NodeJS and configure our browser and capabilities using a config file:
Using the commands we can write tests that make claims about our application and then verify the results. One such test might be to sign up and login to your application and check that a welcome email is sent. The login methods might look like this:
You can create email inboxes on demand with throwaway email addresses using the MailSlurp cypress plugin or by adding commands ourselves to the Cypress client.
Then we can use the commands in our tests to generate real email accounts and use those to sign up users:
Sign up for a free MailSlurp account to start using email in your automated tests today.
Check out our tutorial video series.
Email and SMS guides for automation and testing.
View github project code for multiple languages.
Latest posts from the MailSlurp team.
Test, build, and automate messaging with a free MailSlurp account.