Package org.apache.myfaces.test.mock.visit

Examples of org.apache.myfaces.test.mock.visit.MockVisitCallback


        FacesContext facesContext = FacesContext.getCurrentInstance();
        VisitContextFactory factory = new MockVisitContextFactory();
        VisitContext visitContext = factory.getVisitContext(facesContext, null,
                null);

        VisitCallback callback = new MockVisitCallback();
        UIComponent component = facesContext.getViewRoot();
        assertEquals(VisitResult.ACCEPT, visitContext.invokeVisitCallback(
                component, callback));
    }
View Full Code Here


        UIViewRoot viewRoot = _facesContext.getViewRoot();

        VisitContext visitCtx = VisitContext.createVisitContext(_facesContext,
                null, null);
        viewRoot.visitTree(visitCtx, new MockVisitCallback());
    }
View Full Code Here

   
    public void testVisitTree() throws Exception {
        UIComponent parent = MockRenderedValueExpression.setUpComponentStack(facesContext, input, true);
       
        VisitContext visitContext = VisitContext.createVisitContext(facesContext, null, EnumSet.of(VisitHint.SKIP_UNRENDERED));
        MockVisitCallback mockVisitCallback = new MockVisitCallback();
        input.visitTree(visitContext, mockVisitCallback);
       
        assertEquals("visitTree must not change currentComponent", parent, UIComponent.getCurrentComponent(facesContext));
    }
View Full Code Here

TOP

Related Classes of org.apache.myfaces.test.mock.visit.MockVisitCallback

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.