public void RetrieveDeliveryErrorsTest()
 {
     var result = new DeliveryErrorsResponseResult {
         DSNCode = "403",
         messageId = "TEST",
         time = DateTime.Now,
         toEmail = "*****@*****.**"
     };
     MockHttpClient.Expect(
         x =>
         x.RetrieveDeliveryErrors(
             Arg<DateTime>.Is.Equal(DateTime.Today.AddDays(-1)),
             Arg<DateTime>.Is.Equal(DateTime.Today),
             Arg<String>.Is.Equal(null)))
         .Return(new DeliveryErrorsResponse {
             statusCode = 200,
             results = new List<DeliveryErrorsResponseResult> {
                 result
             }
         });
     var startDate = DateTime.Today.AddDays(-1);
     var endDate = DateTime.Today;
     var actual = StatsClient.RetrieveDeliveryErrors(startDate, endDate, null);
     Assert.AreEqual("403", actual[0].DSNCode);
     Assert.AreEqual("TEST", actual[0].MessageId);
     Assert.AreEqual("*****@*****.**", actual[0].ToEmail);
 }
 public MessageBusDeliveryErrorResult(DeliveryErrorsResponseResult result)
 {
     ToEmail = result.toEmail;
     MessageId = result.messageId;
     Time = result.time;
     DSNCode = result.DSNCode;
     tags = result.tags;
 }