| Conditions | 4 |
| Paths | 3 |
| Total Lines | 10 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 4 |
| CRAP Score | 4.5923 |
| Changes | 0 | ||
| 1 | <?php |
||
| 17 | 37 | protected function validateSaveable(\Dtc\QueueBundle\Model\Job $job) |
|
| 18 | { |
||
| 19 | 37 | if (null !== $job->getPriority() && !isset($this->maxPriority)) { |
|
| 20 | throw new PriorityException('This queue does not support priorities'); |
||
| 21 | } |
||
| 22 | |||
| 23 | 37 | if (!$job instanceof RetryableJob) { |
|
| 24 | throw new ClassNotSubclassException('Job needs to be instance of '.RetryableJob::class); |
||
| 25 | } |
||
| 26 | 37 | } |
|
| 27 | } |
||
| 28 |