/**
  * @test
  */
 public function shouldUpdateVersionInEmConf()
 {
     $service = new EmConfService($this->root->url(), 'extension_manager');
     $service->updateVersion('47.11.4711');
     $service->write();
     $this->assertRegExp('~\'version\' => \'47\\.11\\.4711\'~', $this->emConf->getContent());
 }
 /**
  * @param InputInterface $input
  * @param OutputInterface $output
  * @return void
  */
 protected function execute(InputInterface $input, OutputInterface $output)
 {
     $service = new EmConfService($input->getArgument('path'), $input->getArgument('extension'));
     if ($output->getVerbosity() >= OutputInterface::VERBOSITY_VERBOSE) {
         $output->writeln(sprintf('<info>Updating EMCONF for extension "%s" in path "%s".</info>', $input->getArgument('extension'), $input->getArgument('path')));
     }
     if ($input->getOption('version-number')) {
         if ($output->getVerbosity() >= OutputInterface::VERBOSITY_VERBOSE) {
             $output->writeln(sprintf('<info>...updating version to "%s".</info>', $input->getOption('version-number')));
         }
         $service->updateVersion($input->getOption('version-number'));
     }
     $service->write();
 }