Add tests for user authentication