org.opensubsystems.security.logic
Class AuthenticationControllerTest.AuthenticationControllerTestInternal

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by org.opensubsystems.core.persist.db.DatabaseTest
              extended by org.opensubsystems.security.persist.db.SecureDatabaseTest
                  extended by org.opensubsystems.security.logic.AuthenticationControllerTest.AuthenticationControllerTestInternal
All Implemented Interfaces:
junit.framework.Test
Enclosing class:
AuthenticationControllerTest

public static class AuthenticationControllerTest.AuthenticationControllerTestInternal
extends SecureDatabaseTest

Internal class which can be included in other test suites directly without including the above suite. This allows us to group multiple tests together and the execute the DatabaseTestSetup only once


Field Summary
protected  org.opensubsystems.security.logic.AuthenticationController m_authenticateControl
          Controller used to authenticate users.
protected  org.opensubsystems.security.persist.RoleFactory m_roleFactory
          Factory to manage roles.
protected  org.opensubsystems.security.logic.UserController m_userControl
          Controller used to manipulate users.
 
Fields inherited from class org.opensubsystems.core.persist.db.DatabaseTest
DEFAULT_DB_PASSWORD, DEFAULT_DB_USER, DEFAULT_PROPERTY_FILE, m_connection, m_iRequestedConnectionCount, m_transaction
 
Constructor Summary
AuthenticationControllerTest.AuthenticationControllerTestInternal(java.lang.String strTestName)
          Constructor
 
Method Summary
 void testVerifyAndCurrentUser()
          Test for verifying and returning of current user
 void testVerifyAndReturnGuestUser()
          Test for verifying and returning of guest user
 void testVerifyAndReturnGuestUserByID()
          Test for verifying and returning of guest user, when we know just user ID
 void testVerifyAndReturnGuestUserByIDWithNoGuest()
          Test for verifying and returning of guest user knowing just user ID
 void testVerifyAndReturnGuestUserWithNoGuest()
          Test for verifying and returning of guest user
 void testVerifyAndReturnUserById()
          Test for verifying and returning of user
 void testVerifyAndReturnUserByNameAndPassword()
          Test for verifying and returning of user
 
Methods inherited from class org.opensubsystems.security.persist.db.SecureDatabaseTest
setUp, tearDown
 
Methods inherited from class org.opensubsystems.core.persist.db.DatabaseTest
addDataSource, addDataSource, getDataSourceName, setDataSourceName
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runBare, runTest, setName, toString
 
Methods inherited from class junit.framework.Assert
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail, failNotEquals, failNotSame, failSame
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

m_roleFactory

protected org.opensubsystems.security.persist.RoleFactory m_roleFactory
Factory to manage roles.


m_userControl

protected org.opensubsystems.security.logic.UserController m_userControl
Controller used to manipulate users.


m_authenticateControl

protected org.opensubsystems.security.logic.AuthenticationController m_authenticateControl
Controller used to authenticate users.

Constructor Detail

AuthenticationControllerTest.AuthenticationControllerTestInternal

public AuthenticationControllerTest.AuthenticationControllerTestInternal(java.lang.String strTestName)
                                                                  throws java.lang.Exception
Constructor

Parameters:
strTestName - - name of the test
Throws:
java.lang.Exception - - an error has occured
Method Detail

testVerifyAndReturnUserByNameAndPassword

public void testVerifyAndReturnUserByNameAndPassword()
                                              throws java.lang.Exception
Test for verifying and returning of user

Throws:
java.lang.Exception - - an error has occured

testVerifyAndReturnUserById

public void testVerifyAndReturnUserById()
                                 throws java.lang.Exception
Test for verifying and returning of user

Throws:
java.lang.Exception - - an error has occured

testVerifyAndCurrentUser

public void testVerifyAndCurrentUser()
                              throws java.lang.Exception
Test for verifying and returning of current user

Throws:
java.lang.Exception - - an error has occured

testVerifyAndReturnGuestUser

public void testVerifyAndReturnGuestUser()
                                  throws java.lang.Exception
Test for verifying and returning of guest user

Throws:
java.lang.Exception - - an error has occured

testVerifyAndReturnGuestUserWithNoGuest

public void testVerifyAndReturnGuestUserWithNoGuest()
                                             throws java.lang.Exception
Test for verifying and returning of guest user

Throws:
java.lang.Exception - - an error has occured

testVerifyAndReturnGuestUserByID

public void testVerifyAndReturnGuestUserByID()
                                      throws java.lang.Exception
Test for verifying and returning of guest user, when we know just user ID

Throws:
java.lang.Exception - - an error has occured

testVerifyAndReturnGuestUserByIDWithNoGuest

public void testVerifyAndReturnGuestUserByIDWithNoGuest()
                                                 throws java.lang.Exception
Test for verifying and returning of guest user knowing just user ID

Throws:
java.lang.Exception - - an error has occured


Copyright © 2003 - 2006 OpenSubsystems s.r.o.