Refactored the ControllerDatabaseTest class.