From 9b6ef8beef7d166fb2002b223ed0b9658453e3d5 Mon Sep 17 00:00:00 2001 From: Ivan Sidorov Date: Tue, 13 Feb 2024 14:21:57 +0000 Subject: [PATCH] Failed and regression tests with creation of a list of issues Failed tests: ``` 1) Psalm\Tests\MagicMethodAnnotationTest::testInvalidCodeWithIssues with data set "staticInvocationWithMagicMethodFoo" UnexpectedValueException: Cannot get method params for A::foo 2) Psalm\Tests\MagicMethodAnnotationTest::testInvalidCodeWithIssues with data set "nonStaticSelfCallWithMagicMethodFoo" UnexpectedValueException: Cannot get method params for B::foo ``` --- tests/MagicMethodAnnotationTest.php | 2 ++ tests/MagicPropertyTest.php | 2 ++ tests/MethodCallTest.php | 2 ++ tests/MethodSignatureTest.php | 2 ++ tests/MixinAnnotationTest.php | 2 ++ 5 files changed, 10 insertions(+) diff --git a/tests/MagicMethodAnnotationTest.php b/tests/MagicMethodAnnotationTest.php index 1ec6b125d78..109dc08fd28 100644 --- a/tests/MagicMethodAnnotationTest.php +++ b/tests/MagicMethodAnnotationTest.php @@ -6,12 +6,14 @@ use Psalm\Context; use Psalm\Exception\CodeException; use Psalm\Tests\Traits\InvalidCodeAnalysisTestTrait; +use Psalm\Tests\Traits\InvalidCodeAnalysisWithIssuesTestTrait; use Psalm\Tests\Traits\ValidCodeAnalysisTestTrait; use const DIRECTORY_SEPARATOR; class MagicMethodAnnotationTest extends TestCase { + use InvalidCodeAnalysisWithIssuesTestTrait; use InvalidCodeAnalysisTestTrait; use ValidCodeAnalysisTestTrait; diff --git a/tests/MagicPropertyTest.php b/tests/MagicPropertyTest.php index 27b5b36a5ea..bc1e89faffe 100644 --- a/tests/MagicPropertyTest.php +++ b/tests/MagicPropertyTest.php @@ -6,12 +6,14 @@ use Psalm\Context; use Psalm\Exception\CodeException; use Psalm\Tests\Traits\InvalidCodeAnalysisTestTrait; +use Psalm\Tests\Traits\InvalidCodeAnalysisWithIssuesTestTrait; use Psalm\Tests\Traits\ValidCodeAnalysisTestTrait; use const DIRECTORY_SEPARATOR; class MagicPropertyTest extends TestCase { + use InvalidCodeAnalysisWithIssuesTestTrait; use InvalidCodeAnalysisTestTrait; use ValidCodeAnalysisTestTrait; diff --git a/tests/MethodCallTest.php b/tests/MethodCallTest.php index def613cc537..3426aa38a55 100644 --- a/tests/MethodCallTest.php +++ b/tests/MethodCallTest.php @@ -4,12 +4,14 @@ use Psalm\Context; use Psalm\Tests\Traits\InvalidCodeAnalysisTestTrait; +use Psalm\Tests\Traits\InvalidCodeAnalysisWithIssuesTestTrait; use Psalm\Tests\Traits\ValidCodeAnalysisTestTrait; use const DIRECTORY_SEPARATOR; class MethodCallTest extends TestCase { + use InvalidCodeAnalysisWithIssuesTestTrait; use InvalidCodeAnalysisTestTrait; use ValidCodeAnalysisTestTrait; diff --git a/tests/MethodSignatureTest.php b/tests/MethodSignatureTest.php index c47fd247020..69315f41797 100644 --- a/tests/MethodSignatureTest.php +++ b/tests/MethodSignatureTest.php @@ -5,12 +5,14 @@ use Psalm\Context; use Psalm\Exception\CodeException; use Psalm\Tests\Traits\InvalidCodeAnalysisTestTrait; +use Psalm\Tests\Traits\InvalidCodeAnalysisWithIssuesTestTrait; use Psalm\Tests\Traits\ValidCodeAnalysisTestTrait; use const DIRECTORY_SEPARATOR; class MethodSignatureTest extends TestCase { + use InvalidCodeAnalysisWithIssuesTestTrait; use ValidCodeAnalysisTestTrait; use InvalidCodeAnalysisTestTrait; diff --git a/tests/MixinAnnotationTest.php b/tests/MixinAnnotationTest.php index 1769546aab2..88529223bd8 100644 --- a/tests/MixinAnnotationTest.php +++ b/tests/MixinAnnotationTest.php @@ -3,10 +3,12 @@ namespace Psalm\Tests; use Psalm\Tests\Traits\InvalidCodeAnalysisTestTrait; +use Psalm\Tests\Traits\InvalidCodeAnalysisWithIssuesTestTrait; use Psalm\Tests\Traits\ValidCodeAnalysisTestTrait; class MixinAnnotationTest extends TestCase { + use InvalidCodeAnalysisWithIssuesTestTrait; use ValidCodeAnalysisTestTrait; use InvalidCodeAnalysisTestTrait;