public function setUp() { $this->input = new ArrayInput([]); $this->output = new StreamOutput(fopen('php://memory', 'w', false)); ConsoleRunner::runApplication($this->input, $this->output, FALSE); $this->app = ConsoleRunner::getApplication(); }
/** * Runs the console application. */ public static function runApplication(InputInterface $input = NULL, OutputInterface $output = NULL, $auto_exit = TRUE) { self::$runningApp = new static(); self::$runningApp->setAutoExit($auto_exit); self::$runningApp->run($input, $output); }