| Total Lines | 16 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 1 |
| 1 | <?php |
||
| 53 | public function testGetParameters() |
||
| 54 | { |
||
| 55 | $instanciator = new ConstructorLessInstanciator; |
||
| 56 | $object = new class('bar') { |
||
| 57 | public function __construct(string $foo) |
||
|
|
|||
| 58 | { |
||
| 59 | } |
||
| 60 | }; |
||
| 61 | |||
| 62 | $this->assertSame( |
||
| 63 | [], |
||
| 64 | unwrap($instanciator->parameters('stdClass')), |
||
| 65 | ); |
||
| 66 | $this->assertSame( |
||
| 67 | [], |
||
| 68 | unwrap($instanciator->parameters(get_class($object))), |
||
| 69 | ); |
||
| 72 |
This check looks for parameters that have been defined for a function or method, but which are not used in the method body.