Example #1
0
        public void getSubscribedUserTest()
        {
            DBSubscribedUser db   = DBSubscribedUser.getInstance();
            string           pass = DomainBridge.getInstance().encryptPassword("etay123");
            Session          s    = new Session();

            s.register("etay11", pass);
            Assert.AreNotEqual(db.getSubscribedUser("etay11"), null);
        }
Example #2
0
        public void getSubscribedUserTest()
        {
            DBSubscribedUser db = DBSubscribedUser.getInstance();
            Session          s  = new Session();

            s.register("etay", "etay");
            Assert.AreNotEqual(db.getSubscribedUser("etay"), null);
            db.cleanDB();
        }
Example #3
0
        public void logoutTest()
        {
            DBSubscribedUser db   = DBSubscribedUser.getInstance();
            Session          s    = new Session();
            string           pass = DomainBridge.getInstance().encryptPassword("etay123");

            s.register("etay", pass);
            s.login("etay", "etay123");
            if (db.getSubscribedUser("etay") == null)
            {
                Assert.Fail();
            }
            s.logout();
            Assert.AreEqual(null, db.getloggedInUser("etay"));
        }
Example #4
0
        public void logoutTest()
        {
            DBSubscribedUser db = DBSubscribedUser.getInstance();

            db.cleanDB();
            Session s = new Session();

            s.register("etay", "etay");
            s.login("etay", "etay");
            if (db.getSubscribedUser("etay") == null)
            {
                Assert.Fail();
            }
            s.logout();
            Assert.AreEqual(null, db.getloggedInUser("etay"));
        }