예제 #1
0
 public function testFileMissingChangeBase()
 {
     FileExists::setBasePath('src');
     $fe = new FileExists('_i_don_t_exist');
     $this->assertFalse($fe());
     FileExists::resetBasePath();
 }
예제 #2
0
 protected function updateDependencies()
 {
     $this->info('Updating dependencies and running asset pipelines...');
     FileExists::setBasePath(function_exists('base_path') ? base_path() : getcwd());
     $commands = [['npm install', new FileExists('package.json')], ['bower install', new FileExists('bower.json')], ['gulp --production', new FileExists('gulpfile.js')]];
     foreach ($commands as $command) {
         list($cmd, $condition) = $command;
         $this->conditionalProcess($cmd, $condition, 0);
     }
 }