6768697071727374757677
replay(actionBean); replay(mapping); replay(request); ViewAdapter viewAdapter = action.executeAction(actionBean, new TestContextImpl(request, null, null, null, mapping)); ActionForwardViewAdapter va = (ActionForwardViewAdapter) viewAdapter; assert (va.getActionForward() == actionForward); verify(actionBean);
9899100101102103104105106107108
128129130131132133134135136137138
replay(mapping); replay(request); try { action.executeAction(actionBean, new TestContextImpl(request, null, null, null, mapping)); } catch (ApplicationConfigurationException e) { Assert .assertEquals(e.getMessage(),
6162636465666768697071
replay(request); replay(session); InjectionWrapper inputWrapper = inputs.get("redirectParameter"); ActionContext injectionContext = new TestContextImpl(request); inputWrapper.inject(action, injectionContext); verify(request); verify(session);
9293949596979899100101102
123124125126127128129130131132133
replay(request); InjectionWrapper inputWrapper = inputs.get("redirectParameter"); ActionContext injectionContext = new TestContextImpl(request); inputWrapper.inject(action, injectionContext); verify(request); assert action.getRedirectParameter() == null;
4849505152535455565758
replay(context); InjectionWrapper inputWrapper = inputs.get("context"); ActionContext injectionContext = new TestContextImpl(context); inputWrapper.inject(action, injectionContext); verify(context); assert action.getContext() != null;
114115116117118119120121122123124
replay(servlet); replay(context); replay(messageResources); replay(form); ViewAdapter viewAdapter = action.executeAction(actionBean, new TestContextImpl(request, null, null, form, mapping)); ActionForwardViewAdapter va = (ActionForwardViewAdapter) viewAdapter; assert (va.getActionForward() == actionForward); verify(actionBean);
182183184185186187188189190191192
replay(context); replay(messageResources); try { action.executeAction(actionBean, new TestContextImpl(request, null, null, null, mapping)); } catch (ApplicationRuntimeException e) { Assert .assertEquals(e.getMessage(),
226227228229230231232233234235236