| Conditions | 3 |
| Paths | 4 |
| Total Lines | 20 |
| Code Lines | 12 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 13 |
| CRAP Score | 3.1172 |
| Changes | 0 | ||
| 1 | <?php |
||
| 59 | 2 | final protected function configure() |
|
| 60 | { |
||
| 61 | 2 | $signature = (new SignatureParser())->parse($this->signature); |
|
| 62 | |||
| 63 | 2 | $this->setName($signature['name']); |
|
| 64 | 2 | $this->setDescription($this->description); |
|
| 65 | |||
| 66 | 2 | foreach ($signature['arguments'] as $argument) { |
|
| 67 | 2 | $this->addArgument( |
|
| 68 | 2 | $argument['name'], |
|
| 69 | 2 | $argument['type'], |
|
| 70 | 2 | $argument['description'], |
|
| 71 | 2 | $argument['default'] |
|
| 72 | ); |
||
| 73 | } |
||
| 74 | |||
| 75 | 2 | foreach ($signature['options'] as $option) { |
|
| 76 | 2 | $this->addOption($option['name'], null, $option['type'], $option['description'], $option['default']); |
|
| 77 | } |
||
| 78 | 2 | } |
|
| 79 | |||
| 94 | } |