public void Test_AddHeaders() { var mail = BasicMailBuilder .AddHeaders(new Dictionary <string, string>() { { "X-TEST", "MAILBUILDER" }, { "X-TEST-2", "SENDGRID" } }) .Build(); var message = new SendGridMessage(); message.Headers.Add("X-TEST", "MAILBUILDER"); message.Headers.Add("X-TEST-2", "SENDGRID"); Assert.IsTrue(mail.Headers.All(e => message.Headers.Contains(e))); }