@Test
public void testOnTerminatedNonBranchExecution() {

	List<ExecutionMessage> messages = new ArrayList<>();
	messages.add(createExecutionMessage());
	messages.add(createExecutionMessage());
	ScoreEvent event1 = new ScoreEvent("type1", "event1");
	ScoreEvent event2 = new ScoreEvent("type1", "event2");
	when(scoreEventFactory.createFinishedEvent(any(Execution.class))).thenReturn(event1, event2);
	queueListener.onTerminated(messages);
	verify(executionStateService, times(1)).deleteExecutionState(Long.valueOf(messages.get(0).getMsgId()), ExecutionSummary.EMPTY_BRANCH);
	verify(executionStateService, times(1)).deleteExecutionState(Long.valueOf(messages.get(1).getMsgId()), ExecutionSummary.EMPTY_BRANCH);
}