| Conditions | 1 |
| Paths | 1 |
| Total Lines | 10 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 14 | public function testConstructorVariants(): void |
||
| 15 | { |
||
| 16 | // Constructor with pre-loaded model |
||
| 17 | $user = new User(); |
||
| 18 | $resource = new ModelResource(User::class, $user); |
||
| 19 | self::assertSame($user, $resource->getInstance(), 'should be able to get back model'); |
||
| 20 | self::assertSame('User#null', $resource->getName(), 'should have unique name'); |
||
| 21 | |||
| 22 | $resourceWithoutInstance = new ModelResource(User::class); |
||
| 23 | self::assertSame('User#null', $resourceWithoutInstance->getName(), 'should have name even without instance'); |
||
| 24 | } |
||
| 33 |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths