Site icon Mailtrap

How to Test Emails in Mandrill, Sendgrid, and Mailgun

In our previous post, we reviewed Sendgrid, Mandrill, and Mailgun – the most popular email sending services. “Test your emails before actually sending them”: each of them repeats this mantra, as does anyone who deals with email development. But do these services offer enough options for quality email testing? Let’s have a closer look at the checkpoints and see if there is a need for a special testing service.

Sendgrid test

Sendgrid offers sandbox mode and sink email addresses for email developers.

  1. Test the API integration in the sandbox mode. In Sendgrid, it’s a mail_settings parameter, which helps validate email sending requests. Sandbox mode allows checking the parameters of your JSON payload. If any errors are found, it returns their detailed description. You can find more information and examples in Sendgrid documentation. It doesn’t affect any of the real sending parameters.
  2. Check the email sending speed. This option can be useful for preparing large bulk email campaigns. Sendgrid has a “black hole” domain @sink.sendgrid.net. It will accept all the messages and immediately remove them. If you have a dedicated IP address, this type of test won’t affect its warm-up. However, all emails sent to this domain will be counted as billable.

Mandrill test

The testing mode in Mandrill offers a more extensive list of features: test API, test stats, and webhooks testing.

  1. With the test API key, you will be able to verify your integration and explore its capabilities. As no actual email sending occurs, it affects neither your monthly limits nor your account reputation.
  2. In Mandrill’s test mode, you have access to your test stats. Also, you can view and check the email subject, sender and receiver email address as well as the message content.
  3. Another interesting feature is webhooks testing. Mandrill provides you with a list of specific email addresses. You can use them to send a message for testing such events as bounces, rejects, and spam complaints.

Read more about these options in the Mandrill knowledge base.

Mailgun test

Mailgun features a very simple test mode and an email verification tool.

  1. To launch the test mode, you should simply set the o:testmode parameter to true. It will help to test your integration as well. Note that Mailgun charges you for the messages sent in this mode.
  2. Email verification tool is a specific feature in Mailgun. It is useful for bulk email campaigns. The tool will check all email addresses in your list to identify invalid ones. It helps to decrease the hard bounce rate, which has a negative influence on your sending reputation. Note that email verification is a separate limit, not included in the email sending volume.

Universal Email Testing Checklist for Developers

Each of the mentioned email services recommends running a series of tests before sending either transactional or bulk emails. See below the list of checks that you can perform for any type of email or framework.

1. Testing the email sending capability. It is actually where you check if your code works.

Check if your script is able to send messages in general. As a rule of thumb, separate production (real) email sending from staging or sandbox testing. You don’t want your tests to reach your customers or affect your domain reputation score.

2. Content testing. Regardless of the method you use to compose your message, there is a chance that your input will differ from the output – the message your user will see in the end.

3. Spam testing.

In addition, you can share the testing results with your team members or even forward your message to your inbox for preview.

To get the full list of checks, refer to our Email Testing Checklist article.

Test Your Emails Now

Tools and Options for Email Testing

When it comes to email testing, the first thing that probably comes to mind is creating several test accounts with the most popular email clients like Gmail, AppleMail, Outlook, or Thunderbird. This will let you instantly check the delivery speed, see in which folder your message landed as well as review the email content and how it is rendered. Also, using this method, you can open testing emails on your smartphone and/or tablet to see their responsiveness.

Still, it’s important to note that although setting up test accounts with several webmail services and/or email clients can bring you good results, it will work well only if you occasionally need to test new templates. Otherwise, you might become overwhelmed with maintaining all your accounts’ inboxes and cleaning out test emails.

In addition, since this falls under production testing, it will affect your monthly credits and sending reputation. 

All in all, it’s safe to say that when you need to test bulk email sending that includes dynamic content and localization, other methods should be explored, preferably ones that involve feature-packed tools.

One such tool is Mailtrap Email Sandbox which is primarily geared towards devs and QAs who want to inspect and debug emails in staging without the risk of spamming recipients in the process. 

What’s especially great about Mailtrap Email Sandbox is that it’s capable of running all the necessary tests we mentioned earlier:

Other features of the tool that might come in handy during email testing include HTML/CSS analysis, email forwarding to whitelisted recipients, and insight into detailed tech info.

To start using Email Sandbox, you’ll need to create a Mailtrap account and complete a 5-minute setup process. And, once you are a registered Mailtrap user, besides email testing, you will also be able to deliver emails to recipients from your account using Email API – the email sending side of the Mailtrap Email Delivery Platform.

Try Mailtrap for Free

Email Testing Outcomes

A lot of email sending providers offer quite limited testing capabilities. More importantly, they hardly allow users to separate email sending from development and production environments. Instead, some of them just feature third-party apps, which might help you with testing.

So, if you’re looking for a platform you can test, send, and control emails with in one place and don’t want to pay for multiple services, we would recommend going with Mailtrap. It will serve as a reliable end-to-end sending solution for most developers, QAs, and managers.

Still, regardless of what tool(s)/service(s) you go for and what your testing workflows look like, don’t forget to cover the three main steps:

Only with these steps out of the way will you be able to avoid many of the common errors that occur in email sending.

Good luck and till next time!

Exit mobile version