Fixed the login method call in test_login_logout_works_properly