refactoring login, registration tests