Example #1
0
        public static void MessageInfoContactTest()
        {
            const string phoneNumber = "8080808080";
            const string firstName   = "Test Name";
            const string lastName    = "Test Last Name";
            const string userId      = "0545006540";

            dynamic MessageInfoContact = mMandatoryFieldsMessageInfo;

            MessageInfoContact.contact = ContactInfoObject.GetObject(phoneNumber, firstName, lastName,
                                                                     userId);

            MessageInfo messageInfo = new MessageInfo(MessageInfoContact);

            //test MessageInfo.Contact
            Assert.AreEqual(messageInfo.Contact.PhoneNumber, phoneNumber);
            Assert.AreEqual(messageInfo.Contact.FirstName, firstName);
            Assert.AreEqual(messageInfo.Contact.LastName, lastName);
            Assert.AreEqual(messageInfo.Contact.UserId, userId);

            Console.WriteLine(MessageInfoContact);
        }
Example #2
0
        public static void MessageInfoContactTest()
        {
            const string phoneNumber = "8080808080";
            const string firstName   = "Test Name";
            const string lastName    = "Test Last Name";
            const string userId      = "0545006540";

            dynamic messageInfoContact = MCommonMandatoryFieldsMessageInfo;

            messageInfoContact.contact = ContactInfoObject.GetObject(phoneNumber, firstName, lastName,
                                                                     userId);

            MessageInfo messageInfo = new MessageInfo(messageInfoContact);

            Assert.Multiple(() =>
            {
                Assert.AreEqual(phoneNumber, messageInfo.Contact.PhoneNumber);
                Assert.AreEqual(firstName, messageInfo.Contact.FirstName);
                Assert.AreEqual(lastName, messageInfo.Contact.LastName);
                Assert.AreEqual(userId, messageInfo.Contact.UserId);
            });
        }