Reduced LoginTest's complexity with method extraction