From fd9fb0f4c13d97b4e26ad8eaa1f813ec5fbc6ac5 Mon Sep 17 00:00:00 2001 From: Bruce Weirdan Date: Sun, 24 May 2020 22:29:12 +0300 Subject: [PATCH 1/2] Updated codeception module to get regexp support --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 4d3f1b4..1131c9b 100755 --- a/composer.json +++ b/composer.json @@ -24,7 +24,7 @@ "require-dev": { "codeception/codeception": "^4.0.3", "squizlabs/php_codesniffer": "^3.3.1", - "weirdan/codeception-psalm-module": "^0.4.0" + "weirdan/codeception-psalm-module": "^0.7.1" }, "extra": { "psalm": { From 786e0bd1d338d4a8f0634f748eea633bef493073 Mon Sep 17 00:00:00 2001 From: Bruce Weirdan Date: Sun, 24 May 2020 22:29:52 +0300 Subject: [PATCH 2/2] Updated tests to account for changed Psalm output Psalm started to distinguish shapes from tuples so its error messages changed. --- tests/acceptance/TestCase.feature | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/tests/acceptance/TestCase.feature b/tests/acceptance/TestCase.feature index 1b76693..d987ccf 100644 --- a/tests/acceptance/TestCase.feature +++ b/tests/acceptance/TestCase.feature @@ -421,8 +421,8 @@ Feature: TestCase """ When I run Psalm Then I see these errors - | Type | Message | - | InvalidArgument | Argument 1 of NS\MyTestCase::testSomething expects int, string provided by NS\MyTestCase::provide():(iterable) | + | Type | Message | + | InvalidArgument | /Argument 1 of NS\\MyTestCase::testSomething expects int, string provided by NS\\MyTestCase::provide\(\):\(iterable\)/ | And I see no other errors Scenario: Invalid dataset array is reported @@ -469,8 +469,8 @@ Feature: TestCase """ When I run Psalm Then I see these errors - | Type | Message | - | TooFewArguments | Too few arguments for NS\MyTestCase::testSomething - expecting at least 2, but saw 1 provided by NS\MyTestCase::provide():(iterable) | + | Type | Message | + | TooFewArguments | /Too few arguments for NS\\MyTestCase::testSomething - expecting at least 2, but saw 1 provided by NS\\MyTestCase::provide\(\):\(iterable\)/ | And I see no other errors Scenario: Referenced providers are not marked as unused @@ -960,8 +960,8 @@ Feature: TestCase """ When I run Psalm Then I see these errors - | Type | Message | - | TooFewArguments | Too few arguments for NS\MyTestCase::testSomething - expecting at least 2, but saw 1 provided by NS\MyTestCase::provide():(iterable) | + | Type | Message | + | TooFewArguments | /Too few arguments for NS\\MyTestCase::testSomething - expecting at least 2, but saw 1 provided by NS\\MyTestCase::provide\(\):\(iterable\)/ | And I see no other errors Scenario: Providers generating incompatible datasets for variadic tests are reported