refactored switch to if/else statement in TestDatabaseActivity.java file