add login and tests