Exemple #1
0
 /**
  * Registers the given plugin namespace. The instance of the Enlight_Plugin_PluginManager is
  * set into the namespace by using the Enlight_Plugin_Namespace::setManager() function.
  * The namespace name is used as array key.
  *
  * @param Enlight_Plugin_Namespace $namespace
  * @return Enlight_Plugin_PluginManager
  */
 public function registerNamespace(Enlight_Plugin_Namespace $namespace)
 {
     $namespace->setManager($this);
     $this->plugins[$namespace->getName()] = $namespace;
     return $this;
 }
Exemple #2
0
 public function testSetManager()
 {
     $manager = $this->getMock('Enlight_Plugin_PluginCollection', array('Application'), array(), '', false);
     $this->namespace->setManager($manager);
     $this->assertInstanceOf('Enlight_Plugin_PluginCollection', $this->namespace->Manager());
 }