Example #1
0
 /**
  * {@inheritDoc}
  */
 protected function initialize(InputInterface $input, OutputInterface $output)
 {
     parent::initialize($input, $output);
     if ($input->getOption('em')) {
         CommandHelper::setApplicationEntityManager($this->getHelper('container'), $input->getOption('em'));
     }
     $this->cacheCleaner->invalidate();
 }
 /**
  * {@inheritDoc}
  */
 protected function execute(InputInterface $input, OutputInterface $output)
 {
     DoctrineCommandHelper::setApplicationEntityManager($this->getApplication(), $input->getOption('em'));
     parent::execute($input, $output);
 }
 protected function initialize(InputInterface $input, OutputInterface $output)
 {
     parent::initialize($input, $output);
     $this->cacheCleaner->invalidate();
 }
Example #4
0
 public function testListAllClasses()
 {
     $this->tester->execute(array('command' => $this->command->getName()));
     $this->assertContains('Doctrine\\Tests\\Models\\Cache\\AttractionInfo', $this->tester->getDisplay());
     $this->assertContains('Doctrine\\Tests\\Models\\Cache\\City', $this->tester->getDisplay());
 }
 /**
  * @expectedException \InvalidArgumentException
  * @expectedExceptionMessage Could not find any mapped Entity classes matching "AttractionFooBar"
  */
 public function testShowSpecificNotFound()
 {
     $this->tester->execute(array('command' => $this->command->getName(), 'entityName' => 'AttractionFooBar'));
 }
 protected function initialize(InputInterface $input, OutputInterface $output)
 {
     parent::initialize($input, $output);
     Debugger::$productionMode = !$input->getOption('debug-mode');
     $this->cacheCleaner->invalidate();
 }