Esempio n. 1
0
        public void CastRoleTest()
        {
            User user = new User("agent");
            bool expected = true;
            bool actual = user.Login("agent");
            Assert.AreEqual(expected, actual);

            user = user.Find();
            User target = (User)user;
            if (target is Agent)
                Assert.IsTrue(true);
            else
                Assert.IsTrue(false);
        }
Esempio n. 2
0
 public void LoginPassTest()
 {
     User user = new User("agent");
     bool expected = true;
     bool actual = user.Login("agent");
     Assert.AreEqual(expected, actual);
 }
Esempio n. 3
0
 public void LoginFailTest()
 {
     User user = new User("A999");
     bool expected = false;
     bool actual = user.Login("W002");
     Assert.AreEqual(expected, actual);
 }