/** * {@inheritdoc} */ protected function execute(InputInterface $input, OutputInterface $output) { $bbapp = $this->getContainer()->get('bbapp'); $publicResourcesDir = $bbapp->getBaseDir() . '/public/ressources'; $bbappResourcesDir = $bbapp->getBBDir() . '/Resources'; $repoResourcesDir = $bbapp->getBaseRepository() . '/Ressources'; Dir::copy($repoResourcesDir, $publicResourcesDir, 0755); Dir::copy($bbappResourcesDir, $publicResourcesDir, 0755); foreach ($bbapp->getBundles() as $bundle) { Dir::copy($bundle->getResourcesDir(), $publicResourcesDir, 0755); } }
/** * @expectedException PHPUnit_Framework_Error_Warning */ public function testUnreadableCopy() { $this->assertFalse(Dir::copy($this->copyFolder, $this->privateFolder)); }