Fixed login test helper