We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
| Conditions | 3 |
| Paths | 3 |
| Total Lines | 14 |
| Code Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 8 |
| CRAP Score | 3 |
| Changes | 0 | ||
| 1 | <?php |
||
| 40 | 12 | public function assert($input) |
|
| 41 | { |
||
| 42 | 12 | if ($this->validate($input)) { |
|
| 43 | 8 | return true; |
|
| 44 | } |
||
| 45 | |||
| 46 | 4 | $rule = $this->rule; |
|
| 47 | 4 | if ($rule instanceof AllOf) { |
|
| 48 | 2 | $rule = $this->absorbAllOf($rule, $input); |
|
| 49 | } |
||
| 50 | |||
| 51 | throw $rule |
||
| 52 | 4 | ->reportError($input) |
|
| 53 | 4 | ->setMode(ValidationException::MODE_NEGATIVE); |
|
| 54 | } |
||
| 75 |