| Conditions | 5 |
| Paths | 5 |
| Total Lines | 18 |
| Lines | 18 |
| Ratio | 100 % |
| Tests | 3 |
| CRAP Score | 5 |
| Changes | 0 | ||
| 1 | <?php |
||
| 34 | protected function validateConfig(): void |
||
| 35 | 3 | { |
|
| 36 | 1 | if (! isset($this->options['host'])) { |
|
| 37 | throw new UnexpectedValueException("Missing 'host' as option"); |
||
| 38 | 2 | } |
|
| 39 | |||
| 40 | if (! isset($this->options['port'])) { |
||
| 41 | throw new UnexpectedValueException("Missing 'port' as option"); |
||
| 42 | } |
||
| 43 | |||
| 44 | if (! isset($this->options['username'])) { |
||
| 45 | throw new UnexpectedValueException("Missing 'username' as option"); |
||
| 46 | } |
||
| 47 | |||
| 48 | if (! isset($this->options['password'])) { |
||
| 49 | throw new UnexpectedValueException("Missing 'password' as option"); |
||
| 50 | } |
||
| 51 | } |
||
| 52 | } |
||
| 53 |