Skip to content

Commit

Permalink
Drop support for ancient Psalm versions
Browse files Browse the repository at this point in the history
  • Loading branch information
weirdan committed May 20, 2022
1 parent 253f1c9 commit 241bb4e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 23 deletions.
7 changes: 5 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
},
"require-dev": {
"squizlabs/php_codesniffer": "^3.4",
"vimeo/psalm": "^3.7.0 || ^4.0.0 || dev-master",
"vimeo/psalm": "^4.17.0 || dev-master",
"phpunit/phpunit": "^9.5.20",
"codeception/codeception": "^4.1.31 || ^5.0.0-rc3"
},
Expand All @@ -40,6 +40,9 @@
"test": "codecept run -v"
},
"config": {
"optimize-autoloader": true
"optimize-autoloader": true,
"allow-plugins": {
"composer/package-versions-deprecated": true
}
}
}
23 changes: 2 additions & 21 deletions tests/acceptance/PsalmModule.feature
Original file line number Diff line number Diff line change
Expand Up @@ -204,27 +204,8 @@ Feature: Psalm module
| UndefinedClass | /\bP{3}\b does not exist/ |
And I see no other errors

Scenario: Psalm crashes (3.7.x)
Given I have Psalm older than "3.8.0" (because of "exit code changed in 3.8.0")
And I have the following code in "autoload.php"
"""
<?php missing_function();
"""
And I have the following config
"""
<?xml version="1.0"?>
<psalm errorLevel="1" autoloader="autoload.php">
<projectFiles>
<directory name="."/>
</projectFiles>
</psalm>
"""
When I run Psalm
Then I see exit code 255

Scenario: Psalm crashes (3.8.0+)
Given I have Psalm newer than "3.7.2" (because of "exit code changed in 3.8.0")
And I have the following code in "autoload.php"
Scenario: Psalm crashes
Given I have the following code in "autoload.php"
"""
<?php missing_function_2();
"""
Expand Down

0 comments on commit 241bb4e

Please sign in to comment.