Skip to content

Commit 6551043

Browse files
committed
Replace Psalm with PHPstan
1 parent ae77515 commit 6551043

33 files changed

+673
-312
lines changed

.github/workflows/php.yml

Lines changed: 6 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -162,9 +162,8 @@ jobs:
162162
with:
163163
# Should be the higest supported version, so we can use the newest tools
164164
php-version: '8.4'
165-
tools: composer, composer-require-checker, composer-unused, phpcs, psalm
166-
# optional performance gain for psalm: opcache
167-
extensions: ctype, date, dom, fileinfo, filter, hash, intl, mbstring, opcache, openssl, pcre, spl, xml
165+
tools: composer, composer-require-checker, composer-unused, phpcs
166+
extensions: ctype, date, dom, fileinfo, filter, hash, intl, mbstring, openssl, pcre, spl, xml
168167

169168
- name: Setup problem matchers for PHP
170169
run: echo "::add-matcher::${{ runner.tool_cache }}/php.json"
@@ -196,27 +195,13 @@ jobs:
196195
- name: PHP Code Sniffer
197196
run: phpcs
198197

199-
- name: Psalm
200-
continue-on-error: true
201-
run: |
202-
psalm -c psalm.xml \
203-
--show-info=true \
204-
--shepherd \
205-
--php-version=${{ steps.setup-php.outputs.php-version }}
206-
207-
- name: Psalm (testsuite)
198+
- name: PHPStan
208199
run: |
209-
psalm -c psalm-dev.xml \
210-
--show-info=true \
211-
--shepherd \
212-
--php-version=${{ steps.setup-php.outputs.php-version }}
200+
vendor/bin/phpstan analyze -c phpstan.neon
213201
214-
- name: Psalter
202+
- name: PHPStan (testsuite)
215203
run: |
216-
psalm --alter \
217-
--issues=UnnecessaryVarAnnotation \
218-
--dry-run \
219-
--php-version=${{ steps.setup-php.outputs.php-version }}
204+
vendor/bin/phpstan analyze -c phpstan-dev.neon
220205
221206
security:
222207
name: Security checks

composer.json

Lines changed: 10 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -36,24 +36,18 @@
3636
"ext-SimpleXML": "*",
3737
"ext-session": "*",
3838

39-
"simplesamlphp/assert": "^1.1",
40-
"simplesamlphp/composer-module-installer": "^1.3",
41-
"simplesamlphp/simplesamlphp": "^2.3",
42-
"simplesamlphp/xml-cas": "^1.3",
43-
"simplesamlphp/xml-common": "^1.17",
44-
"simplesamlphp/xml-soap": "^1.5",
45-
"symfony/http-foundation": "^6.4",
46-
"symfony/http-kernel": "^6.4",
47-
"simplesamlphp/saml11": "~1.2.4"
39+
"simplesamlphp/assert": "~1.8.2",
40+
"simplesamlphp/composer-module-installer": "~1.4.0",
41+
"simplesamlphp/simplesamlphp": "~2.4.2",
42+
"simplesamlphp/xml-cas": "~2.0.0",
43+
"simplesamlphp/xml-common": "~2.0.0",
44+
"simplesamlphp/xml-soap": "~2.0.0",
45+
"symfony/http-foundation": "~6.4.0",
46+
"symfony/http-kernel": "~6.4.0",
47+
"simplesamlphp/saml11": "~1.2.5"
4848
},
4949
"require-dev": {
50-
"simplesamlphp/simplesamlphp-test-framework": "^1.7",
51-
"phpunit/phpunit": "^10",
52-
"psalm/plugin-phpunit": "^0.19.0",
53-
"squizlabs/php_codesniffer": "^3.7",
54-
"maglnet/composer-require-checker": "4.7.1",
55-
"vimeo/psalm": "^5",
56-
"icanhazstring/composer-unused": "^0.8.11"
50+
"simplesamlphp/simplesamlphp-test-framework": "~1.9.2"
5751
},
5852
"support": {
5953
"issues": "https://github.com/simplesamlphp/simplesamlphp-module-casserver/issues",

0 commit comments

Comments
 (0)