コード例 #1
0
        public void Test_EnablingSpamCheck_2_url()
        {
            var mail = BasicMailBuilder
                       .EnableSpamCheck(score: 2, url: "http://spamcheck.example.com")
                       .Build();

            var message = new SendGridMessage();

            message.EnableSpamCheck(score: 2, url: "http://spamcheck.example.com");
            Assert.IsFalse(string.IsNullOrEmpty(message.Header.JsonString()));
            Assert.AreEqual(message.Header.JsonString(), mail.Header.JsonString());
        }
コード例 #2
0
        public void Test_EnablingSpamCheck()
        {
            var mail = BasicMailBuilder
                       .EnableSpamCheck()
                       .Build();

            var message = new SendGridMessage();

            message.EnableSpamCheck();
            Assert.IsFalse(string.IsNullOrEmpty(message.Header.JsonString()));
            Assert.AreEqual(message.Header.JsonString(), mail.Header.JsonString());
        }