public function initSeeInOutputTrait($container, $input = null) { $this->capturedOutput = ''; $this->testPrinter = new BufferedOutput(OutputInterface::VERBOSITY_DEBUG); $app = Robo::createDefaultApplication(); $config = new \Robo\Config(); \Robo\Robo::configureContainer($container, $app, $config, $input, $this->testPrinter); // Set the application dispatcher $app->setDispatcher($container->get('eventDispatcher')); $this->logger = $container->get('logger'); }
/** * @param array $argv * @param null|string $appName * @param null|string $appVersion * @param null|\Symfony\Component\Console\Output\OutputInterface $output * * @return int */ public function execute($argv, $appName = null, $appVersion = null, $output = null) { $argv = $this->shebang($argv); $argv = $this->processRoboOptions($argv); $app = null; if ($appName && $appVersion) { $app = Robo::createDefaultApplication($appName, $appVersion); } $commandFiles = $this->getRoboFileCommands($output); return $this->run($argv, $output, $app, $commandFiles); }