jwage /
usage-finder
| 1 | <?php |
||||
| 2 | |||||
| 3 | declare(strict_types=1); |
||||
| 4 | |||||
| 5 | namespace UsageFinder\Tests; |
||||
| 6 | |||||
| 7 | use PHPUnit\Framework\TestCase; |
||||
| 8 | use UsageFinder\ClassMethodUsage; |
||||
| 9 | |||||
| 10 | final class ClassMethodUsageTest extends TestCase |
||||
| 11 | { |
||||
| 12 | public function testGetFile() : void |
||||
| 13 | { |
||||
| 14 | self::assertSame('src/Test.php', (new ClassMethodUsage('src/Test.php', 1, '', ''))->getFile()); |
||||
| 15 | } |
||||
| 16 | |||||
| 17 | public function testGetLine() : void |
||||
| 18 | { |
||||
| 19 | self::assertSame(1, (new ClassMethodUsage('src/Test.php', 1, '', ''))->getLine()); |
||||
| 20 | } |
||||
| 21 | |||||
| 22 | public function testGetConsoleSnippet() : void |
||||
| 23 | { |
||||
| 24 | self::assertSame( |
||||
|
0 ignored issues
–
show
Bug
Best Practice
introduced
by
Loading history...
|
|||||
| 25 | '$variable-><info>method</info>();', |
||||
|
0 ignored issues
–
show
'$variable-><info>method</info>();' of type string is incompatible with the type PHPUnit\Framework\T expected by parameter $expected of PHPUnit\Framework\Assert::assertSame().
(
Ignorable by Annotation
)
If this is a false-positive, you can also ignore this issue in your code via the
Loading history...
|
|||||
| 26 | (new ClassMethodUsage('src/Test.php', 1, '$variable->method();', 'method'))->getConsoleSnippet() |
||||
| 27 | ); |
||||
| 28 | } |
||||
| 29 | } |
||||
| 30 |