@Test public void test() { QueueAsynchActionExecution sut = new QueueAsynchActionExecution("key"); final List<UserActionRequest> list = new ArrayList<UserActionRequest>(); context.checking(new Expectations() { { allowing(actionContext).getUserActionRequests(); will(returnValue(list)); } }); sut.execute(actionContext); assertEquals(1, list.size()); context.assertIsSatisfied(); }
@Override public Serializable execute(final TaskHandlerActionContext<ActionContext> inActionContext) { if (actionKey != null && !actionKey.isEmpty()) { inActionContext.getUserActionRequests().add(new UserActionRequest(actionKey, null, null)); } return null; }
QueueAsynchActionExecution implements TaskHandlerExecutionStrategy<ActionContext> { @Override public Serializable execute(final TaskHandlerActionContext<ActionContext> inActionContext) { if (actionKey != null && !actionKey.isEmpty()) { inActionContext.getUserActionRequests().add(new UserActionRequest(actionKey, null, null)); } return null; } }
QueueAsynchActionExecution implements TaskHandlerExecutionStrategy<ActionContext> { @Override public Serializable execute(final TaskHandlerActionContext<ActionContext> inActionContext) { if (actionKey != null && !actionKey.isEmpty()) { inActionContext.getUserActionRequests().add(new UserActionRequest(actionKey, null, null)); } return null; } QueueAsynchActionExecution(final String inActionKey); }
QueueAsynchActionExecution implements TaskHandlerExecutionStrategy<ActionContext> { @Override public Serializable execute(final TaskHandlerActionContext<ActionContext> inActionContext) { if (actionKey != null && !actionKey.isEmpty()) { inActionContext.getUserActionRequests().add(new UserActionRequest(actionKey, null, null)); } return null; } QueueAsynchActionExecution(final String inActionKey); @Override Serializable execute(final TaskHandlerActionContext<ActionContext> inActionContext); }
QueueAsynchActionExecution implements TaskHandlerExecutionStrategy<ActionContext> { @Override public Serializable execute(final TaskHandlerActionContext<ActionContext> inActionContext) { if (actionKey != null && !actionKey.isEmpty()) { inActionContext.getUserActionRequests().add(new UserActionRequest(actionKey, null, null)); } return null; } QueueAsynchActionExecution(final String inActionKey); @Override Serializable execute(final TaskHandlerActionContext<ActionContext> inActionContext);  }