Skip to content

Commit 6ad6fc9

Browse files
staabmondrejmirtes
authored andcommitted
Cleanup AnalyserIntegrationTest->runAnalyse()
1 parent 7ceeb21 commit 6ad6fc9

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

tests/PHPStan/Analyser/AnalyserIntegrationTest.php

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
use Bug4288\MyClass;
66
use Bug4713\Service;
77
use ExtendingKnownClassWithCheck\Foo;
8-
use PHPStan\File\FileHelper;
98
use PHPStan\Reflection\InitializerExprContext;
109
use PHPStan\Reflection\InitializerExprTypeResolver;
1110
use PHPStan\Reflection\ParametersAcceptorSelector;
@@ -1307,13 +1306,11 @@ public function testBug10538(): void
13071306
private function runAnalyse(string $file, ?array $allAnalysedFiles = null): array
13081307
{
13091308
$file = $this->getFileHelper()->normalizePath($file);
1310-
/** @var Analyser $analyser */
1309+
13111310
$analyser = self::getContainer()->getByType(Analyser::class);
1312-
/** @var FileHelper $fileHelper */
1313-
$fileHelper = self::getContainer()->getByType(FileHelper::class);
13141311
$errors = $analyser->analyse([$file], null, null, true, $allAnalysedFiles)->getErrors();
13151312
foreach ($errors as $error) {
1316-
$this->assertSame($fileHelper->normalizePath($file), $error->getFilePath());
1313+
$this->assertSame($file, $error->getFilePath());
13171314
}
13181315

13191316
return $errors;

0 commit comments

Comments
 (0)