Refactoring. New test for authenticator class.