Ejemplo n.º 1
0
 /**
  * Execute the command.
  *
  * @return void
  */
 public function fire()
 {
     $this->config->set('enabled', false);
     $fetcher = new Fetcher();
     $converter = new Converter(base_path() . '/vendor/pragmarx/ua-parser/php/resources/');
     $converter->convertString($fetcher->fetch(), false);
 }
Ejemplo n.º 2
0
 public function testFileIsNotBackedUp()
 {
     $this->fs->expects($this->once())->method('exists')->with($this->yamlFile)->will($this->returnValue(true));
     $this->fs->expects($this->never())->method('copy');
     $this->fs->expects($this->once())->method('dumpFile')->with($this->phpFile, $this->php);
     $this->converter->convertFile($this->yamlFile, false);
 }
Ejemplo n.º 3
0
 protected function execute(InputInterface $input, OutputInterface $output)
 {
     $fetcher = new Fetcher();
     $converter = new Converter($this->resourceDirectory);
     $converter->convertString($fetcher->fetch(), !$input->getOption('no-backup'));
 }