public void Can_Send_ProtoBuf_request()
        {
            var client = new ProtoBufServiceClient(Config.ServiceStackBaseUri);

            var request = new ProtoBufEmail {
                ToAddress      = "*****@*****.**",
                FromAddress    = "*****@*****.**",
                Subject        = "Subject",
                Body           = "Body",
                AttachmentData = Encoding.UTF8.GetBytes("AttachmentData"),
            };

            try
            {
                var response = client.Send <ProtoBufEmail>(request);

                Console.WriteLine(response.Dump());

                Assert.That(response.Equals(request));
            }
            catch (WebServiceException webEx)
            {
                Console.WriteLine(webEx.ResponseDto.Dump());
                Assert.Fail(webEx.Message);
            }
        }
		public bool Equals(ProtoBufEmail other)
		{
			if (ReferenceEquals(null, other)) return false;
			if (ReferenceEquals(this, other)) return true;
			return Equals(other.ToAddress, ToAddress) 
				&& Equals(other.FromAddress, FromAddress) 
				&& Equals(other.Subject, Subject) 
				&& Equals(other.Body, Body)
				&& other.AttachmentData.EquivalentTo(AttachmentData);
		}
        private static ProtoBufEmail CreateProtoBufEmail()
        {
            var request = new ProtoBufEmail
            {
                ToAddress      = "*****@*****.**",
                FromAddress    = "*****@*****.**",
                Subject        = "Subject",
                Body           = "Body",
                AttachmentData = Encoding.UTF8.GetBytes("AttachmentData"),
            };

            return(request);
        }
 public bool Equals(ProtoBufEmail other)
 {
     if (ReferenceEquals(null, other))
     {
         return(false);
     }
     if (ReferenceEquals(this, other))
     {
         return(true);
     }
     return(Equals(other.ToAddress, ToAddress) &&
            Equals(other.FromAddress, FromAddress) &&
            Equals(other.Subject, Subject) &&
            Equals(other.Body, Body) &&
            other.AttachmentData.EquivalentTo(AttachmentData));
 }
 public object Any(ProtoBufEmail request)
 {
     return(request);
 }
		public void Can_Send_ProtoBuf_request()
		{
			var client = new ProtoBufServiceClient(Config.ServiceStackBaseUri);

			var request = new ProtoBufEmail {
				ToAddress = "*****@*****.**",
				FromAddress = "*****@*****.**",
				Subject = "Subject",
				Body = "Body",
				AttachmentData = Encoding.UTF8.GetBytes("AttachmentData"),
			};

			try
			{
				var response = client.Send<ProtoBufEmail>(request);

				Console.WriteLine(response.Dump());

				Assert.That(response.Equals(request));
			}
			catch (WebServiceException webEx)
			{
				Console.WriteLine(webEx.ResponseDto.Dump());
				Assert.Fail(webEx.Message);
			}
		}
        public object Any(ProtoBufEmail request)
		{
			return request;
		}
 private static ProtoBufEmail CreateProtoBufEmail()
 {
     var request = new ProtoBufEmail
     {
         ToAddress = "*****@*****.**",
         FromAddress = "*****@*****.**",
         Subject = "Subject",
         Body = "Body",
         AttachmentData = Encoding.UTF8.GetBytes("AttachmentData"),
     };
     return request;
 }