public function testApiTimes_AttachesProperTimesHandler_UsingSeveralHandlers(EventEmitterInterface $emitter) { $emitter->times('A', 2, $this->expectCallableExactly(2)); $emitter->times('B', 3, $this->expectCallableExactly(3)); for ($i = 0; $i < 3; $i++) { $emitter->emit('A'); $emitter->emit('B'); } }