boolean hasError = aggregateOriginalResults(originalTestResult,
consumerResultAggregator,
producerResultAggregator);
ParticipantResult aggregatedProducerResult = producerResultAggregator.getAggregatedResult();
ParticipantResult aggregaredConsumerResult = consumerResultAggregator.getAggregatedResult();
ParticipantResult aggregatedAllResult = aggregateAggregatedResults(
aggregatedResultsAggregator, aggregatedProducerResult,
aggregaredConsumerResult);
applyNonAggregateablesToAll(aggregatedAllResult,
aggregatedProducerResult, aggregaredConsumerResult);
AggregatedTestResult newTestResult = new AggregatedTestResult(originalTestResult);
newTestResult.setAllProducerParticipantResult(aggregatedProducerResult);
newTestResult.setAllConsumerParticipantResult(aggregaredConsumerResult);
newTestResult.setAllParticipantResult(aggregatedAllResult);
if (hasError)
{
aggregatedAllResult.setErrorMessage(TestResultAggregator.AGGREGATED_ERROR_MESSAGE);
}
return newTestResult;
}