Authenticate user and tests