Examples of VolantisProtocolStub


Examples of com.volantis.mcs.protocols.VolantisProtocolStub

        ContextInternals.setEnvironmentContext(requestContext,
                                               new TestEnvironmentContext());

        pageContext = new TestMarinerPageContext();
        requestContext.setMarinerPageContext(pageContext);
        protocol = new VolantisProtocolStub();
        pageContext.setProtocol(protocol);
       
        final RuntimeProjectMock projectMock =
                new RuntimeProjectMock("projectMock", expectations);
View Full Code Here

Examples of com.volantis.mcs.protocols.VolantisProtocolStub

        pageContext = new TestMarinerPageContext();
        requestContext = new TestMarinerRequestContext();
        // Register a dummy EnvironmentContext against the request context
        ContextInternals.setEnvironmentContext(requestContext,
                                               new TestEnvironmentContext());
        VolantisProtocol protocol = new VolantisProtocolStub();       
        pageContext.setProtocol(protocol);
        pageContext.setPageGenerationCache(new PageGenerationCache());
        pageContext.setRequestURL(
                new MarinerURL("http://server:8080/volantis/test.xdime"));
        ContextInternals.setMarinerPageContext(requestContext, pageContext);
        protocol.setMarinerPageContext(pageContext);

        // Create the xfform form element surrounding the xfimplicit. This is
        // required as XFImplicitElement.elementStart gets the current element
        // from the page context.
        formElement = new XFFormElementImpl();
View Full Code Here

Examples of com.volantis.mcs.protocols.VolantisProtocolStub

    /**
     * Sets the protocol used to one that doesn't support native markup
     */  
    private void useNativeMarkupNotSupportedProtocol()
    {
        VolantisProtocolStub protocol = new VolantisProtocolStub();
        protocol.setOutputBufferFactory(bufferFactory);
        pageContext.setProtocol(protocol);
    }
View Full Code Here

Examples of com.volantis.mcs.protocols.VolantisProtocolStub

        public int invokeElementStartEnd(MarinerRequestContext requestContext,
                                         ReturnsIntInvoker invoker)
                throws PAPIException {
            TestMarinerPageContext pageContext = (TestMarinerPageContext)
                    ((TestMarinerRequestContext) requestContext).getMarinerPageContext();
            VolantisProtocol newProtocol = new VolantisProtocolStub() {
                public void writeOpenSpan(com.volantis.mcs.protocols.SpanAttributes attributes) {
                    writeOpenMarkupHasBeenCalled = true;
                }

                public void writeCloseSpan(com.volantis.mcs.protocols.SpanAttributes attributes) {
View Full Code Here

Examples of com.volantis.mcs.protocols.VolantisProtocolStub

     */
    public void testElementStartImpl() throws Exception {
        PAPIElement element = createTestablePAPIElement();
        TestMarinerPageContext pageContext = new TestMarinerPageContext();
        MarinerRequestContext requestContext = new TestMarinerRequestContext();
        VolantisProtocol protocol = new VolantisProtocolStub();
        pageContext.pushRequestContext(requestContext);
        pageContext.setProtocol(protocol);
        ContextInternals.setMarinerPageContext(requestContext, pageContext);
        protocol.setMarinerPageContext(pageContext);

        pageContext.setPolicyReferenceResolver(
                PolicyReferenceResolverTestHelper.getCommonExpectations(
                        expectations, mockFactory));

View Full Code Here

Examples of com.volantis.mcs.protocols.VolantisProtocolStub

        element = new XFContentElementImpl();

        requestContext = new TestMarinerRequestContext();

        pageContext = new TestMarinerPageContext();
        VolantisProtocolStub protocol = new VolantisProtocolStub();
        protocol.setOutputBufferFactory(bufferFactory);
        pageContext.setProtocol(protocol);

        canvasLayout = new CanvasLayout();
        pane = new Pane(canvasLayout);
        pane.setName("TestPane");
View Full Code Here

Examples of com.volantis.mcs.protocols.VolantisProtocolStub

     * Set up the test cases
     */
    private void privateSetUp() {
   
        requestContext = new TestMarinerRequestContext();
        protocol = new VolantisProtocolStub();

        canvasLayout = new CanvasLayout();
        deviceLayoutContext = new TestDeviceLayoutContext();

        pane = new Pane(canvasLayout);
View Full Code Here

Examples of com.volantis.mcs.protocols.VolantisProtocolStub

        assertEquals("protocol src attribute should be null",
                     null, protocolAttributes.getSrc());
    }

    public void testElementStartSkipBody() throws Exception {
        VolantisProtocolStub protocol = new VolantisProtocolStub() {
            public boolean skipElementBody() {
                return true;
            }
        };
View Full Code Here

Examples of com.volantis.mcs.protocols.VolantisProtocolStub

     * Set up the test cases
     */
    private void privateSetUp() throws RepositoryException {
   
        requestContext = new TestMarinerRequestContext();
        protocol = new VolantisProtocolStub();
   
        canvasLayout = new CanvasLayout();
        deviceLayoutContext = new TestDeviceLayoutContext();

        pane = new Pane(canvasLayout);
View Full Code Here

Examples of com.volantis.mcs.protocols.VolantisProtocolStub

        // enable to informally test the claim in the comment above.
        // enableLog4jDebug();
       
        TestMarinerPageContext pageContext = new TestMarinerPageContext();
        MarinerRequestContext requestContext = new TestMarinerRequestContext();
        VolantisProtocol protocol = new VolantisProtocolStub() {
            public void writeOpenAnchor (
                    com.volantis.mcs.protocols.AnchorAttributes attributes) {
                assertEquals( "", value, attributes.getId());
            }
        };
        pageContext.pushRequestContext(requestContext);
        pageContext.setProtocol(protocol);
        ContextInternals.setMarinerPageContext(requestContext, pageContext);
        protocol.setMarinerPageContext(pageContext);
       
        AnchorElementImpl element = new AnchorElementImpl();
        element.elementStartImpl(requestContext, papiAttrs);
    }
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.