Exemple #1
0
 function testRemoveAll()
 {
     $this->dispatcher->removeAll();
     $this->dispatcher->addSubscriber(new Subscriber());
     $this->dispatcher->removeAll(self::EVENT_FOOL1);
     $this->assertEmpty($this->dispatcher->getListeners(self::EVENT_FOOL1));
     $this->assertNotEmpty($this->dispatcher->getListeners(self::EVENT_FOOL2));
 }
Exemple #2
0
 function registerEvents(Dispatcher $dispatcher)
 {
     $dispatcher->addSubscriber(new \Slince\Application\ErrorHandler());
 }