Rewrite login test according to the new desing.