function it_runs_all_supported_maintainers_before_and_after_each_example(ExampleNode $example, ReflectionMethod $exampReflection, Maintainer $maintainer) { $example->isPending()->willReturn(false); $exampReflection->getParameters()->willReturn(array()); $exampReflection->invokeArgs(Argument::cetera())->willReturn(null); $maintainer->getPriority()->willReturn(1); $maintainer->supports($example)->willReturn(true); $maintainer->prepare($example, Argument::cetera())->shouldBeCalled(); $maintainer->teardown($example, Argument::cetera())->shouldBeCalled(); $this->registerMaintainer($maintainer); $this->run($example); }