public void CopyTo_CopiesAllInterfaceData()
        {
            var original = new TestUser {
                UserId          = Guid.NewGuid(),
                DisplayName     = "Joe Smith",
                EmailAddress    = "*****@*****.**",
                Password        = "******",
                PasswordFormat  = 1,
                PasswordUpdated = new DateTime(2014, 7, 3)
            };

            original.CopyTo(new TestUser()).Should().BeEquivalentTo(original, "otherwise we're missing fields");
        }
Exemplo n.º 2
0
        public void Test_CopyTo_TestUser()
        {
            TestUser user1 = new TestUser();

            user1.ID        = Guid.NewGuid();
            user1.FirstName = "Before";


            TestUser user2 = new TestUser();

            user1.CopyTo(user2);

            Assert.AreEqual(user1.FirstName, user2.FirstName, "The first name wasn't transferred.");
        }