Package test.controller
Class AccountManagerTest
java.lang.Object
test.controller.AccountManagerTest
The AccountManagerTest class contains test cases for the AccountManager class.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidsetUp()Before all test, clear all data in the databasevoidTest case for the login method of AccountManagervoidTest case for the register method of AccountManager
-
Constructor Details
-
AccountManagerTest
public AccountManagerTest()
-
-
Method Details
-
setUp
@BeforeEach public void setUp()Before all test, clear all data in the database -
testRegister
@Test @DisplayName("Test Register") public void testRegister() throws ModelNotFoundException, ModelAlreadyExistsExceptionTest case for the register method of AccountManager- Throws:
ModelNotFoundException- if the model cannot be found in the repositoryModelAlreadyExistsException- if the model already exists in the repository
-
testLogin
@Test @DisplayName("Test Login") public void testLogin() throws PasswordIncorrectException, ModelNotFoundException, ModelAlreadyExistsExceptionTest case for the login method of AccountManager- Throws:
PasswordIncorrectException- if the password provided is incorrectModelNotFoundException- if the model cannot be found in the repositoryModelAlreadyExistsException- if the model already exists in the repository
-