1
0
mirror of https://github.com/danog/psalm.git synced 2025-01-22 05:41:20 +01:00

Fix default test versions to 7.3

This commit is contained in:
Matthew Brown 2019-02-07 15:27:43 -05:00
parent ed4ed957c8
commit a6755cc523
13 changed files with 18 additions and 2 deletions

View File

@ -80,13 +80,17 @@ class ConfigTest extends TestCase
*/ */
private function getProjectAnalyzerWithConfig(Config $config) private function getProjectAnalyzerWithConfig(Config $config)
{ {
return new \Psalm\Internal\Analyzer\ProjectAnalyzer( $p = new \Psalm\Internal\Analyzer\ProjectAnalyzer(
$config, $config,
new \Psalm\Internal\Provider\Providers( new \Psalm\Internal\Provider\Providers(
$this->file_provider, $this->file_provider,
new Provider\FakeParserCacheProvider() new Provider\FakeParserCacheProvider()
) )
); );
$p->setPhpVersion('7.3');
return $p;
} }
/** /**

View File

@ -76,6 +76,8 @@ class DocumentationTest extends TestCase
new Provider\FakeParserCacheProvider() new Provider\FakeParserCacheProvider()
) )
); );
$this->project_analyzer->setPhpVersion('7.3');
} }
/** /**

View File

@ -29,6 +29,7 @@ class FileReferenceTest extends TestCase
); );
$this->project_analyzer->getCodebase()->collectReferences(); $this->project_analyzer->getCodebase()->collectReferences();
$this->project_analyzer->setPhpVersion('7.3');
} }
/** /**

View File

@ -39,6 +39,7 @@ class AnalyzedMethodTest extends \Psalm\Tests\TestCase
1, 1,
false false
); );
$this->project_analyzer->setPhpVersion('7.3');
} }
/** /**

View File

@ -39,6 +39,7 @@ class CachedStorageTest extends \Psalm\Tests\TestCase
1, 1,
false false
); );
$this->project_analyzer->setPhpVersion('7.3');
} }
/** /**

View File

@ -39,6 +39,7 @@ class ErrorAfterUpdateTest extends \Psalm\Tests\TestCase
1, 1,
false false
); );
$this->project_analyzer->setPhpVersion('7.3');
} }
/** /**

View File

@ -40,6 +40,7 @@ class ErrorFixTest extends \Psalm\Tests\TestCase
1, 1,
false false
); );
$this->project_analyzer->setPhpVersion('7.3');
} }
/** /**

View File

@ -40,6 +40,7 @@ class TemporaryUpdateTest extends \Psalm\Tests\TestCase
1, 1,
false false
); );
$this->project_analyzer->setPhpVersion('7.3');
} }
/** /**

View File

@ -41,7 +41,7 @@ class CompletionTest extends \Psalm\Tests\TestCase
1, 1,
false false
); );
$this->project_analyzer->setPhpVersion('7.3');
$this->project_analyzer->getCodebase()->server_mode = true; $this->project_analyzer->getCodebase()->server_mode = true;
} }

View File

@ -43,6 +43,7 @@ class SymbolLookupTest extends \Psalm\Tests\TestCase
false false
); );
$this->project_analyzer->setPhpVersion('7.3');
$this->project_analyzer->getCodebase()->server_mode = true; $this->project_analyzer->getCodebase()->server_mode = true;
} }

View File

@ -50,6 +50,7 @@ class StubTest extends TestCase
new Provider\FakeParserCacheProvider() new Provider\FakeParserCacheProvider()
) )
); );
$project_analyzer->setPhpVersion('7.3');
$config->visitComposerAutoloadFiles($project_analyzer, false); $config->visitComposerAutoloadFiles($project_analyzer, false);

View File

@ -29,6 +29,7 @@ class UnusedCodeTest extends TestCase
); );
$this->project_analyzer->getCodebase()->reportUnusedCode(); $this->project_analyzer->getCodebase()->reportUnusedCode();
$this->project_analyzer->setPhpVersion('7.3');
} }
/** /**

View File

@ -28,6 +28,7 @@ class UnusedVariableTest extends TestCase
) )
); );
$this->project_analyzer->setPhpVersion('7.3');
$this->project_analyzer->getCodebase()->reportUnusedCode(); $this->project_analyzer->getCodebase()->reportUnusedCode();
} }