| Conditions | 4 |
| Paths | 4 |
| Total Lines | 10 |
| Code Lines | 6 |
| Lines | 10 |
| Ratio | 100 % |
| Tests | 9 |
| CRAP Score | 4 |
| Changes | 0 | ||
| 1 | <?php |
||
| 32 | 29 | public function apply($instance, stdClass $schema, Context $context, Walker $walker) |
|
| 33 | { |
||
| 34 | 29 | if ($schema->exclusiveMinimum === false) { |
|
| 35 | 22 | if ($instance < $schema->minimum) { |
|
| 36 | 9 | $context->addViolation('should be greater than or equal to %s', [$schema->minimum]); |
|
| 37 | 9 | } |
|
| 38 | 29 | } elseif ($instance <= $schema->minimum) { |
|
| 39 | 4 | $context->addViolation('should be greater than %s', [$schema->minimum]); |
|
| 40 | 4 | } |
|
| 41 | 29 | } |
|
| 42 | } |
||
| 43 |