Ejemplo n.º 1
0
 /**
  * @test
  */
 public function testGenericListenerNotCalledWhenPropogationStopped()
 {
     $this->dispatcher->addListener('ul', function (TranscodeNodeEvent $event) use(&$count) {
         $event->stopPropagation();
     });
     $ulGenericListenerCalled = false;
     $this->dispatcher->addListener('*', function (TranscodeNodeEvent $event) use(&$ulGenericListenerCalled) {
         if ($event->getNode()->nodeName === 'ul') {
             $ulGenericListenerCalled = true;
         }
     });
     $this->transcoder->setAdapter($this->getMockAdapter())->transcode();
     $this->assertFalse($ulGenericListenerCalled);
 }