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