diff --git a/tests/Config/ConfigTest.php b/tests/Config/ConfigTest.php index 531a6e4f3e3..908dc31ef39 100644 --- a/tests/Config/ConfigTest.php +++ b/tests/Config/ConfigTest.php @@ -5,6 +5,7 @@ use Psalm\Context; use Psalm\Exception\ConfigException; use Psalm\Internal\Analyzer\FileAnalyzer; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\RuntimeCaches; use Psalm\Internal\Scanner\FileScanner; use Psalm\Tests\Config\Plugin\FileTypeSelfRegisteringPlugin; @@ -53,7 +54,7 @@ public static function setUpBeforeClass() : void public function setUp() : void { RuntimeCaches::clearAll(); - $this->file_provider = new Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); } private function getProjectAnalyzerWithConfig(Config $config): \Psalm\Internal\Analyzer\ProjectAnalyzer diff --git a/tests/Config/PluginTest.php b/tests/Config/PluginTest.php index 7d2195c00b8..64eda8a895a 100644 --- a/tests/Config/PluginTest.php +++ b/tests/Config/PluginTest.php @@ -9,6 +9,7 @@ use Psalm\Context; use Psalm\FileSource; use Psalm\Internal\IncludeCollector; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\RuntimeCaches; use Psalm\Plugin\EventHandler\AfterCodebasePopulatedInterface; use Psalm\Plugin\EventHandler\AfterEveryFunctionCallAnalysisInterface; @@ -56,7 +57,7 @@ public static function setUpBeforeClass() : void public function setUp() : void { RuntimeCaches::clearAll(); - $this->file_provider = new Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); } private function getProjectAnalyzerWithConfig(Config $config): \Psalm\Internal\Analyzer\ProjectAnalyzer diff --git a/tests/DocumentationTest.php b/tests/DocumentationTest.php index c41101d5333..8bd352017be 100644 --- a/tests/DocumentationTest.php +++ b/tests/DocumentationTest.php @@ -9,6 +9,7 @@ use Psalm\Config; use Psalm\Context; use Psalm\DocComment; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\RuntimeCaches; use Psalm\Tests\Internal\Provider; @@ -125,7 +126,7 @@ public function setUp() : void { RuntimeCaches::clearAll(); - $this->file_provider = new Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); $this->project_analyzer = new \Psalm\Internal\Analyzer\ProjectAnalyzer( new TestConfig(), diff --git a/tests/FileManipulation/ClassConstantMoveTest.php b/tests/FileManipulation/ClassConstantMoveTest.php index c4d2acd7ab1..3c82d141caf 100644 --- a/tests/FileManipulation/ClassConstantMoveTest.php +++ b/tests/FileManipulation/ClassConstantMoveTest.php @@ -2,6 +2,7 @@ namespace Psalm\Tests\FileManipulation; use Psalm\Context; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\RuntimeCaches; use Psalm\Tests\Internal\Provider; use Psalm\Tests\TestConfig; @@ -17,7 +18,7 @@ public function setUp() : void { RuntimeCaches::clearAll(); - $this->file_provider = new Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); } /** diff --git a/tests/FileManipulation/ClassMoveTest.php b/tests/FileManipulation/ClassMoveTest.php index 30def7930b1..736a1bfafd8 100644 --- a/tests/FileManipulation/ClassMoveTest.php +++ b/tests/FileManipulation/ClassMoveTest.php @@ -2,6 +2,7 @@ namespace Psalm\Tests\FileManipulation; use Psalm\Context; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\RuntimeCaches; use Psalm\Tests\Internal\Provider; use Psalm\Tests\TestConfig; @@ -17,7 +18,7 @@ public function setUp() : void { RuntimeCaches::clearAll(); - $this->file_provider = new Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); } /** diff --git a/tests/FileManipulation/FileManipulationTestCase.php b/tests/FileManipulation/FileManipulationTestCase.php index 1fe8646dbe2..3088e23cb4e 100644 --- a/tests/FileManipulation/FileManipulationTestCase.php +++ b/tests/FileManipulation/FileManipulationTestCase.php @@ -2,6 +2,7 @@ namespace Psalm\Tests\FileManipulation; use Psalm\Context; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\RuntimeCaches; use Psalm\Tests\Internal\Provider; use Psalm\Tests\TestConfig; @@ -17,7 +18,7 @@ public function setUp() : void { RuntimeCaches::clearAll(); - $this->file_provider = new Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); } /** diff --git a/tests/FileManipulation/MethodMoveTest.php b/tests/FileManipulation/MethodMoveTest.php index e8ae77855cf..b05c0760a96 100644 --- a/tests/FileManipulation/MethodMoveTest.php +++ b/tests/FileManipulation/MethodMoveTest.php @@ -2,6 +2,7 @@ namespace Psalm\Tests\FileManipulation; use Psalm\Context; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\RuntimeCaches; use Psalm\Tests\Internal\Provider; use Psalm\Tests\TestConfig; @@ -17,7 +18,7 @@ public function setUp() : void { RuntimeCaches::clearAll(); - $this->file_provider = new Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); } /** diff --git a/tests/FileManipulation/NamespaceMoveTest.php b/tests/FileManipulation/NamespaceMoveTest.php index 7de7e2d3dba..80aedbf982f 100644 --- a/tests/FileManipulation/NamespaceMoveTest.php +++ b/tests/FileManipulation/NamespaceMoveTest.php @@ -2,6 +2,7 @@ namespace Psalm\Tests\FileManipulation; use Psalm\Context; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\RuntimeCaches; use Psalm\Tests\Internal\Provider; use Psalm\Tests\TestConfig; @@ -17,7 +18,7 @@ public function setUp() : void { RuntimeCaches::clearAll(); - $this->file_provider = new Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); } /** diff --git a/tests/FileManipulation/PropertyMoveTest.php b/tests/FileManipulation/PropertyMoveTest.php index 2b62f1f1146..3c7fee01594 100644 --- a/tests/FileManipulation/PropertyMoveTest.php +++ b/tests/FileManipulation/PropertyMoveTest.php @@ -2,6 +2,7 @@ namespace Psalm\Tests\FileManipulation; use Psalm\Context; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\RuntimeCaches; use Psalm\Tests\Internal\Provider; use Psalm\Tests\TestConfig; @@ -17,7 +18,7 @@ public function setUp() : void { RuntimeCaches::clearAll(); - $this->file_provider = new Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); } /** diff --git a/tests/FileReferenceTest.php b/tests/FileReferenceTest.php index b7523151253..8bf40381953 100644 --- a/tests/FileReferenceTest.php +++ b/tests/FileReferenceTest.php @@ -2,6 +2,7 @@ namespace Psalm\Tests; use Psalm\Context; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\RuntimeCaches; use Psalm\Tests\Internal\Provider; @@ -17,7 +18,7 @@ public function setUp() : void { RuntimeCaches::clearAll(); - $this->file_provider = new Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); $this->project_analyzer = new \Psalm\Internal\Analyzer\ProjectAnalyzer( new TestConfig(), diff --git a/tests/FileUpdates/AnalyzedMethodTest.php b/tests/FileUpdates/AnalyzedMethodTest.php index d8056788646..59fc3726d91 100644 --- a/tests/FileUpdates/AnalyzedMethodTest.php +++ b/tests/FileUpdates/AnalyzedMethodTest.php @@ -2,6 +2,7 @@ namespace Psalm\Tests\FileUpdates; use Psalm\Internal\Analyzer\ProjectAnalyzer; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\Provider\Providers; use Psalm\Tests\Internal\Provider; use Psalm\Tests\TestConfig; @@ -18,7 +19,7 @@ public function setUp() : void { parent::setUp(); - $this->file_provider = new \Psalm\Tests\Internal\Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); $config = new TestConfig(); diff --git a/tests/FileUpdates/CachedStorageTest.php b/tests/FileUpdates/CachedStorageTest.php index 6c11dff35a1..21e410636cf 100644 --- a/tests/FileUpdates/CachedStorageTest.php +++ b/tests/FileUpdates/CachedStorageTest.php @@ -2,6 +2,7 @@ namespace Psalm\Tests\FileUpdates; use Psalm\Internal\Analyzer\ProjectAnalyzer; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\Provider\Providers; use Psalm\Tests\Internal\Provider; use Psalm\Tests\TestConfig; @@ -18,7 +19,7 @@ public function setUp() : void { parent::setUp(); - $this->file_provider = new \Psalm\Tests\Internal\Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); $config = new TestConfig(); diff --git a/tests/FileUpdates/ErrorAfterUpdateTest.php b/tests/FileUpdates/ErrorAfterUpdateTest.php index d2cb7fa2357..593ca3ca8ff 100644 --- a/tests/FileUpdates/ErrorAfterUpdateTest.php +++ b/tests/FileUpdates/ErrorAfterUpdateTest.php @@ -2,6 +2,7 @@ namespace Psalm\Tests\FileUpdates; use Psalm\Internal\Analyzer\ProjectAnalyzer; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\Provider\Providers; use Psalm\Tests\Internal\Provider; use Psalm\Tests\TestConfig; @@ -19,7 +20,7 @@ public function setUp() : void { parent::setUp(); - $this->file_provider = new \Psalm\Tests\Internal\Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); $config = new TestConfig(); diff --git a/tests/FileUpdates/ErrorFixTest.php b/tests/FileUpdates/ErrorFixTest.php index c4d1185513e..fd57630f9f5 100644 --- a/tests/FileUpdates/ErrorFixTest.php +++ b/tests/FileUpdates/ErrorFixTest.php @@ -2,6 +2,7 @@ namespace Psalm\Tests\FileUpdates; use Psalm\Internal\Analyzer\ProjectAnalyzer; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\Provider\Providers; use Psalm\Tests\Internal\Provider; use Psalm\Tests\TestConfig; @@ -18,7 +19,7 @@ public function setUp() : void { parent::setUp(); - $this->file_provider = new \Psalm\Tests\Internal\Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); $config = new TestConfig(); $config->throw_exception = false; diff --git a/tests/FileUpdates/TemporaryUpdateTest.php b/tests/FileUpdates/TemporaryUpdateTest.php index eb47e994615..0f089636b95 100644 --- a/tests/FileUpdates/TemporaryUpdateTest.php +++ b/tests/FileUpdates/TemporaryUpdateTest.php @@ -2,6 +2,7 @@ namespace Psalm\Tests\FileUpdates; use Psalm\Internal\Analyzer\ProjectAnalyzer; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\Provider\Providers; use Psalm\Tests\Internal\Provider; use Psalm\Tests\TestConfig; @@ -20,7 +21,7 @@ public function setUp() : void { parent::setUp(); - $this->file_provider = new \Psalm\Tests\Internal\Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); $config = new TestConfig(); $config->throw_exception = false; diff --git a/tests/Internal/Provider/FakeFileProvider.php b/tests/Internal/Provider/FakeFileProvider.php deleted file mode 100644 index a9029f8ed18..00000000000 --- a/tests/Internal/Provider/FakeFileProvider.php +++ /dev/null @@ -1,7 +0,0 @@ -file_provider = new Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); $config = new TestConfig(); $config->throw_exception = false; diff --git a/tests/LanguageServer/CompletionTest.php b/tests/LanguageServer/CompletionTest.php index f3ec69cac70..6698224a2fa 100644 --- a/tests/LanguageServer/CompletionTest.php +++ b/tests/LanguageServer/CompletionTest.php @@ -4,6 +4,7 @@ use LanguageServerProtocol\Position; use Psalm\Context; use Psalm\Internal\Analyzer\ProjectAnalyzer; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\Provider\Providers; use Psalm\Tests\Internal\Provider; use Psalm\Tests\TestConfig; @@ -17,7 +18,7 @@ public function setUp() : void { parent::setUp(); - $this->file_provider = new \Psalm\Tests\Internal\Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); $config = new TestConfig(); diff --git a/tests/LanguageServer/FileMapTest.php b/tests/LanguageServer/FileMapTest.php index cc68fc19d02..3c03a40c731 100644 --- a/tests/LanguageServer/FileMapTest.php +++ b/tests/LanguageServer/FileMapTest.php @@ -3,6 +3,7 @@ use Psalm\Context; use Psalm\Internal\Analyzer\ProjectAnalyzer; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\Provider\Providers; use Psalm\Tests\Internal\Provider; use Psalm\Tests\TestConfig; @@ -13,7 +14,7 @@ public function setUp() : void { parent::setUp(); - $this->file_provider = new \Psalm\Tests\Internal\Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); $config = new TestConfig(); diff --git a/tests/LanguageServer/SymbolLookupTest.php b/tests/LanguageServer/SymbolLookupTest.php index 38848221a8d..063229e0558 100644 --- a/tests/LanguageServer/SymbolLookupTest.php +++ b/tests/LanguageServer/SymbolLookupTest.php @@ -5,6 +5,7 @@ use Psalm\Context; use Psalm\Internal\Analyzer\FileAnalyzer; use Psalm\Internal\Analyzer\ProjectAnalyzer; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\Provider\Providers; use Psalm\Tests\Internal\Provider; use Psalm\Tests\TestConfig; @@ -15,7 +16,7 @@ public function setUp() : void { parent::setUp(); - $this->file_provider = new \Psalm\Tests\Internal\Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); $config = new TestConfig(); diff --git a/tests/ProjectCheckerTest.php b/tests/ProjectCheckerTest.php index 85c0cf6c769..1945e923323 100644 --- a/tests/ProjectCheckerTest.php +++ b/tests/ProjectCheckerTest.php @@ -3,6 +3,7 @@ use Psalm\Config; use Psalm\Internal\IncludeCollector; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\RuntimeCaches; use Psalm\Plugin\EventHandler\AfterCodebasePopulatedInterface; use Psalm\Plugin\EventHandler\Event\AfterCodebasePopulatedEvent; @@ -45,7 +46,7 @@ public static function setUpBeforeClass() : void public function setUp() : void { RuntimeCaches::clearAll(); - $this->file_provider = new Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); } private function getProjectAnalyzerWithConfig(Config $config): \Psalm\Internal\Analyzer\ProjectAnalyzer diff --git a/tests/ReportOutputTest.php b/tests/ReportOutputTest.php index 157023a74af..89288bb30c3 100644 --- a/tests/ReportOutputTest.php +++ b/tests/ReportOutputTest.php @@ -5,6 +5,7 @@ use DOMDocument; use Psalm\Context; use Psalm\Internal\Analyzer\ProjectAnalyzer; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\RuntimeCaches; use Psalm\IssueBuffer; use Psalm\Report; @@ -26,7 +27,7 @@ public function setUp() : void // `TestCase::setUp()` creates its own ProjectAnalyzer and Config instance, but we don't want to do that in this // case, so don't run a `parent::setUp()` call here. RuntimeCaches::clearAll(); - $this->file_provider = new Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); $config = new TestConfig(); $config->throw_exception = false; diff --git a/tests/StubTest.php b/tests/StubTest.php index b7d6b588659..63c26f4b273 100644 --- a/tests/StubTest.php +++ b/tests/StubTest.php @@ -4,6 +4,7 @@ use Psalm\Config; use Psalm\Context; use Psalm\Internal\IncludeCollector; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\RuntimeCaches; use Psalm\Tests\Internal\Provider; @@ -37,7 +38,7 @@ public static function setUpBeforeClass() : void public function setUp() : void { RuntimeCaches::clearAll(); - $this->file_provider = new Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); } private function getProjectAnalyzerWithConfig(Config $config): \Psalm\Internal\Analyzer\ProjectAnalyzer diff --git a/tests/TestCase.php b/tests/TestCase.php index f1307cc3798..fd617741ee4 100644 --- a/tests/TestCase.php +++ b/tests/TestCase.php @@ -5,6 +5,7 @@ use Psalm\Config; use Psalm\Internal\Analyzer\FileAnalyzer; use Psalm\Internal\Analyzer\ProjectAnalyzer; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\Provider\Providers; use Psalm\Internal\RuntimeCaches; use Psalm\Tests\Internal\Provider; @@ -26,7 +27,7 @@ class TestCase extends BaseTestCase /** @var ProjectAnalyzer */ protected $project_analyzer; - /** @var Provider\FakeFileProvider */ + /** @var FakeFileProvider */ protected $file_provider; /** @var Config */ @@ -59,7 +60,7 @@ public function setUp() : void RuntimeCaches::clearAll(); - $this->file_provider = new \Psalm\Tests\Internal\Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); $this->testConfig = $this->makeConfig(); diff --git a/tests/TypeComparatorTest.php b/tests/TypeComparatorTest.php index 1e09f6a32ce..8f414a45c86 100644 --- a/tests/TypeComparatorTest.php +++ b/tests/TypeComparatorTest.php @@ -1,6 +1,7 @@ file_provider = new \Psalm\Tests\Internal\Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); $config = new TestConfig(); diff --git a/tests/TypeParseTest.php b/tests/TypeParseTest.php index eee45cd1bca..5d69556b71e 100644 --- a/tests/TypeParseTest.php +++ b/tests/TypeParseTest.php @@ -1,6 +1,7 @@ file_provider = new \Psalm\Tests\Internal\Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); $config = new TestConfig(); diff --git a/tests/TypeReconciliation/ValueTest.php b/tests/TypeReconciliation/ValueTest.php index c02c5377d4c..15c4933f880 100644 --- a/tests/TypeReconciliation/ValueTest.php +++ b/tests/TypeReconciliation/ValueTest.php @@ -1,6 +1,7 @@ file_provider = new \Psalm\Tests\Internal\Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); $this->project_analyzer = new \Psalm\Internal\Analyzer\ProjectAnalyzer( new \Psalm\Tests\TestConfig(), diff --git a/tests/UnusedCodeTest.php b/tests/UnusedCodeTest.php index b597e0df481..29a89de3345 100644 --- a/tests/UnusedCodeTest.php +++ b/tests/UnusedCodeTest.php @@ -3,6 +3,7 @@ use Psalm\Config; use Psalm\Context; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\RuntimeCaches; use Psalm\Tests\Internal\Provider; @@ -15,7 +16,7 @@ public function setUp() : void { RuntimeCaches::clearAll(); - $this->file_provider = new Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); $this->project_analyzer = new \Psalm\Internal\Analyzer\ProjectAnalyzer( new TestConfig(), diff --git a/tests/UnusedVariableTest.php b/tests/UnusedVariableTest.php index 3e8f8865db0..93048b4bf08 100644 --- a/tests/UnusedVariableTest.php +++ b/tests/UnusedVariableTest.php @@ -3,6 +3,7 @@ use Psalm\Config; use Psalm\Context; +use Psalm\Internal\Provider\FakeFileProvider; use Psalm\Internal\RuntimeCaches; use Psalm\Tests\Internal\Provider; @@ -20,7 +21,7 @@ public function setUp() : void { RuntimeCaches::clearAll(); - $this->file_provider = new Provider\FakeFileProvider(); + $this->file_provider = new FakeFileProvider(); $this->project_analyzer = new \Psalm\Internal\Analyzer\ProjectAnalyzer( new TestConfig(),