Ejemplo n.º 1
0
        public void DeleteUserTest()
        {
            FriendUsersTest();
            List <Record> list = DBConnectionHelper.ReadUserRecords();

            Assert.AreEqual(2, list.Count);

            int  id     = Convert.ToInt32(list[0].Entries["ID"]);
            bool actual = DBConnectionHelper.DeleteUser(id);

            Assert.AreEqual(true, actual);
            list = DBConnectionHelper.ReadUserRecords();
            Assert.AreEqual(1, list.Count);

            List <int> buddies = DBConnectionHelper.ReadBuddiesFromUser(id);

            Assert.AreEqual(0, buddies.Count);
        }