コード例 #1
0
 public function testCreateCanonicalizesHomeDirectory()
 {
     $config = new Config();
     $environment = new GlobalEnvironment(__DIR__ . '/../Environment', $config);
     $this->assertSame(__DIR__, $environment->getHomeDirectory());
 }
コード例 #2
0
ファイル: Puli.php プロジェクト: niklongstone/manager
 /**
  * Returns the configuration file manager.
  *
  * @return ConfigFileManager The configuration file manager.
  */
 public function getConfigFileManager()
 {
     if (!$this->started) {
         throw new LogicException('Puli was not started');
     }
     if (!$this->configFileManager && $this->environment->getHomeDirectory()) {
         $this->configFileManager = new ConfigFileManagerImpl($this->environment, $this->getConfigFileStorage(), $this->getFactoryManager());
     }
     return $this->configFileManager;
 }