1 Reply Latest reply on Mar 14, 2008 4:31 PM by Tomas Cirip

    Secure pages, navigation

    Tomas Cirip Newbie


      I am trying to test user navigating to test user entering data on secure page. Authentication works fine but even though checking current id shows userEdit.xhtml when I do client.getWebResponse().getText() it still show HTML generated by the login.xhtml. I think I am missing some basic concept here.



      client = new JSFClientSession("/pages/admin/userEdit.faces");
       JSFServerSession server = new JSFServerSession(client);
       assertEquals("/login.xhtml", server.getCurrentViewID());
       WebForm loginform = client.getWebResponse().getFormWithID("loginForm");
       loginform.setParameter("j_username", "admin@dwavesys.com");
       loginform.setParameter("j_password", "admin");
       server = new JSFServerSession(client);
       assertEquals("/pages/admin/userEdit.xhtml", server.getCurrentViewID());
       client.setParameter("editUserForm:firstName", "Homer");
       client.setParameter("editUserForm:lastName", "Simpson");