| Conditions | 3 |
| Paths | 3 |
| Total Lines | 14 |
| Code Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 9 |
| CRAP Score | 3 |
| Changes | 0 | ||
| 1 | <?php |
||
| 21 | 5 | public function execute(InputInterface $input, OutputInterface $output) |
|
| 22 | { |
||
| 23 | 5 | if(!$this->getService('project')->getBootstrap()){ |
|
| 24 | 1 | throw new \InvalidArgumentException('The bootstrap of the project is not defined'); |
|
| 25 | } |
||
| 26 | |||
| 27 | 4 | $output->writeln(sprintf( |
|
| 28 | 4 | '<info>Installing project %s from %s</info>', |
|
| 29 | 4 | $this->getService('project')->getName(), |
|
| 30 | 4 | $this->getService('project')->getBootstrap()->getPackage() |
|
| 31 | 4 | )); |
|
| 32 | |||
| 33 | 4 | return $this->getService('composer')->createProject($this->getService('project'), $this->getOptions()) === 0 ? ITask::NO_ERROR_CODE : ITask::BLOCKING_ERROR_CODE; |
|
|
|
|||
| 34 | } |
||
| 35 | |||
| 46 |
Overly long lines are hard to read on any screen. Most code styles therefor impose a maximum limit on the number of characters in a line.