Package org.nanocontainer.nanowar

Examples of org.nanocontainer.nanowar.TestAction


*/
public class PicoRequestProcessorTestCase extends AbstractActionTestCase {

    public void testProcessActionCreate() throws IOException {
        PicoRequestProcessor requestProcessor = new PicoRequestProcessor();
        TestAction action = (TestAction) requestProcessor.processActionCreate(request, response, mapping);
        assertNotNull(action);
        assertSame(service, action.getService());
    }
View Full Code Here


*/
public class PicoTilesRequestProcessorTestCase extends AbstractActionTestCase {

    public void testProcessActionCreate() throws IOException {
        PicoTilesRequestProcessor requestProcessor = new PicoTilesRequestProcessor();
        TestAction action = (TestAction) requestProcessor.processActionCreate(request, response, mapping);
        assertNotNull(action);
        assertSame(service, action.getService());
    }
View Full Code Here

        requestMock.stubs().method("getAttribute").with(eq(KeyConstants.ACTIONS_CONTAINER)).will(
                returnValue(actionsContainer));

        StrutsTestAction action1 = (StrutsTestAction) actionFactory.getAction(request, mapping1, servlet);
        StrutsTestAction action2 = (StrutsTestAction) actionFactory.getAction(request, mapping2, servlet);
        TestAction action3 = (TestAction) actionFactory.getAction(request, mapping1, servlet);
        TestAction action4 = (TestAction) actionFactory.getAction(request, mapping2, servlet);

        assertNotNull(action1);
        assertNotNull(action2);
        assertNotSame(action1, action2);
        assertSame(action1, action3);
View Full Code Here

        requestMock.expects(once()).method("getAttribute").with(eq(KeyConstants.REQUEST_CONTAINER)).will(
                returnValue(requestContainer));
        requestMock.expects(once()).method("setAttribute").with(eq(KeyConstants.ACTIONS_CONTAINER),
                isA(MutablePicoContainer.class));

        TestAction action = (TestAction) actionFactory.getAction(request, mapping1, servlet);
        assertNotNull(action);
        assertSame(service, action.getService());
    }
View Full Code Here

        sessionMock.expects(once()).method("getAttribute").with(eq(KeyConstants.SESSION_CONTAINER)).will(
                returnValue(sessionContainer));
        requestMock.expects(once()).method("setAttribute").with(eq(KeyConstants.ACTIONS_CONTAINER),
                isA(MutablePicoContainer.class));

        TestAction action = (TestAction) actionFactory.getAction(request, mapping1, servlet);
        assertNotNull(action);
        assertSame(service, action.getService());
    }
View Full Code Here

        servletContextMock.expects(once()).method("getAttribute").with(eq(KeyConstants.APPLICATION_CONTAINER)).will(
                returnValue(appContainer));
        requestMock.expects(once()).method("setAttribute").with(eq(KeyConstants.ACTIONS_CONTAINER),
                isA(MutablePicoContainer.class));

        TestAction action = (TestAction) actionFactory.getAction(request, mapping1, servlet);
        assertNotNull(action);
        assertSame(service, action.getService());
    }
View Full Code Here

TOP

Related Classes of org.nanocontainer.nanowar.TestAction

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.