| Conditions | 1 |
| Paths | 1 |
| Total Lines | 20 |
| Code Lines | 12 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 21 | public function testCompare() : void |
||
| 22 | { |
||
| 23 | $changes = Changes::fromList(Change::added(uniqid('foo', true), true)); |
||
| 24 | |||
| 25 | /** @var ClassBased|MockObject $classBased */ |
||
| 26 | $classBased = $this->createMock(ClassBased::class); |
||
| 27 | /** @var ReflectionClass|MockObject $fromInterface */ |
||
| 28 | $fromInterface = $this->createMock(ReflectionClass::class); |
||
| 29 | /** @var ReflectionClass|MockObject $toInterface */ |
||
| 30 | $toInterface = $this->createMock(ReflectionClass::class); |
||
| 31 | |||
| 32 | $classBased |
||
| 33 | ->expects(self::once()) |
||
|
|
|||
| 34 | ->method('__invoke') |
||
| 35 | ->with($fromInterface, $toInterface) |
||
| 36 | ->willReturn($changes); |
||
| 37 | |||
| 38 | self::assertSame( |
||
| 39 | $changes, |
||
| 40 | (new UseClassBasedChecksOnAnInterface($classBased))->__invoke($fromInterface, $toInterface) |
||
| 41 | ); |
||
| 44 |
This check looks for calls to methods that do not seem to exist on a given type. It looks for the method on the type itself as well as in inherited classes or implemented interfaces.
This is most likely a typographical error or the method has been renamed.