Esempio n. 1
0
        public void TestUser_CredentialsShouldNotBeExpired()
        {
            UserDTO user = RequestHandler.GetUser();

            Assert.AreEqual(true, user.principal.credentialsNonExpired);
        }
Esempio n. 2
0
        public void TestUser_PrincipalAuthorityShouldBeFan()
        {
            UserDTO user = RequestHandler.GetUser();

            Assert.AreEqual("ROLE_FAN", user.principal.authorities[0].authority);
        }
Esempio n. 3
0
        public void TestUser_ShouldNotBeLocked()
        {
            UserDTO user = RequestHandler.GetUser();

            Assert.AreEqual(true, user.principal.accountNonLocked);
        }
Esempio n. 4
0
        public void TestUser_ShouldBeAuthenticated()
        {
            UserDTO user = RequestHandler.GetUser();

            Assert.AreEqual(true, user.authenticated);
        }
Esempio n. 5
0
        public void TestUser_RemoteAddressShouldBeFilled()
        {
            UserDTO user = RequestHandler.GetUser();

            Assert.AreNotEqual(null, user.details.remoteAddress);
        }
Esempio n. 6
0
        public void TestUsername_ShouldEqualAuthorizations()
        {
            UserDTO user = RequestHandler.GetUser();

            Assert.AreEqual(auth.GetCredential(null, null).UserName.ToLower(), user.principal.username.ToLower());
        }
Esempio n. 7
0
        public void TestPassword_ShouldBeNull()
        {
            UserDTO user = RequestHandler.GetUser();

            Assert.AreEqual(null, user.principal.password);
        }
Esempio n. 8
0
        public void TestAuthorization()
        {
            UserDTO user = RequestHandler.GetUser();

            Assert.AreNotEqual(null, user);
        }
Esempio n. 9
0
        public void TestUser_CredentialsShouldBeNull()
        {
            UserDTO user = RequestHandler.GetUser();

            Assert.AreEqual(null, user.credentials);
        }
Esempio n. 10
0
        public void TestUser_ShouldBeEnabled()
        {
            UserDTO user = RequestHandler.GetUser();

            Assert.AreEqual(true, user.principal.enabled);
        }