function it_throws_AggregateException_if_defined_predictions_fail(MethodProphecy $method1, MethodProphecy $method2, ArgumentsWildcard $arguments1, ArgumentsWildcard $arguments2)
{
$method1->getMethodName()->willReturn('getName');
$method1->getArgumentsWildcard()->willReturn($arguments1);
$method1->checkPrediction()->willReturn(null);
$method2->getMethodName()->willReturn('isSet');
$method2->getArgumentsWildcard()->willReturn($arguments2);
$method2->checkPrediction()->willThrow('Prophecy\\Exception\\Prediction\\AggregateException');
$this->prophesize()->addMethodProphecy($method1);
$this->prophesize()->addMethodProphecy($method2);
$this->shouldThrow('Prophecy\\Exception\\Prediction\\AggregateException')->duringCheckPredictions();
}