| Conditions | 2 |
| Paths | 2 |
| Total Lines | 9 |
| Code Lines | 4 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 5 |
| CRAP Score | 2 |
| Changes | 0 | ||
| 1 | <?php |
||
| 50 | 18 | public function configure(array $config) |
|
| 51 | {
|
||
| 52 | 18 | $this->setName($config[0] ?? 'unknown'); |
|
| 53 | |||
| 54 | 18 | if (count($config) <= 1) {
|
|
| 55 | 1 | throw new \InvalidArgumentException("Minimum format must be satisfied: ['{$this->getName()}', <value>]");
|
|
| 56 | } |
||
| 57 | |||
| 58 | 17 | $this->value = $config[1]; |
|
| 59 | } |
||
| 60 | } |