ParaTest\Console\Testers\PHPUnit::execute PHP Method

execute() public method

Executes the PHPUnit Runner. Will Display help if no config and no path supplied
public execute ( Symfony\Component\Console\Input\InputInterface $input, Symfony\Component\Console\Output\OutputInterface $output ) : integer | mixed
$input Symfony\Component\Console\Input\InputInterface
$output Symfony\Component\Console\Output\OutputInterface
return integer | mixed
    public function execute(InputInterface $input, OutputInterface $output)
    {
        if (!$this->hasConfig($input) && !$this->hasPath($input)) {
            $this->displayHelp($input, $output);
        }
        if ($input->getOption('runner') === 'WrapperRunner') {
            $runner = new WrapperRunner($this->getRunnerOptions($input));
        } else {
            if ($input->getOption('runner') !== '') {
                // because we want to have to bootstrap script inherited before check/initialization
                $runnerOption = $this->getRunnerOptions($input);
                $runnerClass = $input->getOption('runner');
                if (class_exists($runnerClass)) {
                    $runner = new $runnerClass($runnerOption);
                }
            }
        }
        if (!isset($runner)) {
            $runner = new Runner($this->getRunnerOptions($input));
        }
        $runner->run();
        return $runner->getExitCode();
    }