Examples of IDirect


Examples of org.apache.tapestry.IDirect

        MockControl pagec = newControl(IPage.class);
        IPage page = (IPage) pagec.getMock();

        MockControl componentc = newControl(IDirect.class);
        IDirect component = (IDirect) componentc.getMock();

        component.getPage();
        componentc.setReturnValue(page);

        page.getPageName();
        pagec.setReturnValue("Barney");

        component.getIdPath();
        componentc.setReturnValue("foo.bar");

        replayControls();

        DirectCallback callback = new DirectCallback(component, params);

        assertEquals("DirectCallback[Barney/foo.bar p1, p2]", callback.toString());

        verifyControls();

        IRequestCycle cycle = newCycle("Barney", page);

        page.getNestedComponent("foo.bar");
        pagec.setReturnValue(component);

        cycle.setListenerParameters(params);

        component.trigger(cycle);

        replayControls();

        callback.performCallback(cycle);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.