Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nils werner sonarsource/update output provider to differentiate sonarsource products #1

Open
wants to merge 640 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
640 commits
Select commit Hold shift + click to select a range
e0e34be
allow intersections and add test
orklah Sep 11, 2021
bae5b2c
remove type when assertion contradicts the current type
orklah Sep 11, 2021
ae0586b
fix shift inference
orklah Sep 12, 2021
f789ab0
add test and allow checking in already inferred types instead of just…
orklah Sep 12, 2021
a8a6598
add failing test
orklah Sep 12, 2021
c226285
fix Mul and Pow operations
orklah Sep 12, 2021
dd9edb7
fix wrong check for Range validity
orklah Sep 12, 2021
a6630c4
fix mod calculation with ranges
orklah Sep 12, 2021
6b5e6ee
fix wrong type
orklah Sep 12, 2021
e75e390
refactor big methods away
orklah Sep 12, 2021
3d7dc74
fix UnaryMinus
orklah Sep 12, 2021
086d377
fix wrong assertion
orklah Sep 13, 2021
81e8bf3
allow Literals to be combined with preexisting IntRange
orklah Sep 13, 2021
5a2df47
changes after review
orklah Sep 16, 2021
f87bd56
fix Pow
orklah Sep 16, 2021
25f78b5
refine Mod with positives everywhere
orklah Sep 16, 2021
0f17a25
fix Mod
orklah Sep 16, 2021
90e1662
Merge pull request #6241 from orklah/range5
orklah Sep 20, 2021
449ef0d
fixed Uncaught Error: Call to undefined function shell_exec()
thbley Sep 20, 2021
ecb368f
Merge branch 'vimeo:master' into master
thbley Sep 20, 2021
6bb952d
limit PHPParser to 4.12
orklah Sep 20, 2021
9b58871
Merge pull request #6509 from orklah/php-parser-limit
orklah Sep 20, 2021
7328456
Merge pull request #6438 from SCIF/serializable-interface
orklah Sep 20, 2021
994c927
Merge pull request #6445 from TysonAndre/negate-in_array-v2
orklah Sep 20, 2021
55fd9c6
Merge pull request #6478 from whsv26/bugfix/trait-template-invalid-arg
orklah Sep 20, 2021
d32b1be
Merge pull request #6498 from MorrisJobke/fix/catch-ComplicatedExpres…
orklah Sep 20, 2021
e60d9e5
return 1 if shell_exec is not available for getCpuCount()
thbley Sep 20, 2021
6f958fe
Merge branch 'master' of github.com:thomasbley/psalm
thbley Sep 20, 2021
866fa5e
Update to Phpstorm support
ScottAwesome Sep 20, 2021
7e0b489
Merge remote-tracking branch 'origin/master' into if-this-is
danog Sep 21, 2021
ba2c2bd
Fix tests
danog Sep 21, 2021
f8a959c
Fix silly bug
danog Sep 21, 2021
a5af5bd
Update language_server.md
ScottAwesome Sep 21, 2021
15fccc6
Add docs
danog Sep 21, 2021
cf7157f
Merge pull request #6511 from ScottAwesome/patch-1
orklah Sep 21, 2021
9b60c86
Merge pull request #6508 from thomasbley/master
orklah Sep 21, 2021
d2f3ff0
Add possibility to include xml config located in subdirectory
gmessier Sep 21, 2021
741c9ee
Fixes
danog Sep 22, 2021
83d596e
Fixes
danog Sep 22, 2021
84e40ea
Merge branch 'vimeo:master' into hotfix/gmessier-xml-include
gmessier Sep 22, 2021
97a3f54
Add support for advanced IssueHandler in plugins
gmessier Sep 22, 2021
ab7fc8a
Remove temporary testing ugly code
gmessier Sep 22, 2021
12d81fa
Fix inheritance problem using static
gmessier Sep 22, 2021
6e4b4d0
Fix Psalm check errors
gmessier Sep 22, 2021
87f04bf
Fix PHPCS errors
gmessier Sep 22, 2021
666367f
Add unit test
gmessier Sep 23, 2021
7ecb339
Remove PossiblyUnusedMethod for Config::setAdvancedErrorLevel as it i…
gmessier Sep 23, 2021
c74e81c
fix build
orklah Sep 23, 2021
60f0174
Merge pull request #6526 from orklah/fix-build
orklah Sep 23, 2021
ebf777a
Show file and line in case of an exception in a forked worker
MorrisJobke Sep 23, 2021
667eec2
consider count === 0
orklah Sep 4, 2021
7bf9df4
restore paradox checking
orklah Sep 4, 2021
a7fa635
add tests, improve count behaviour on keyed arrays using integer range
orklah Sep 4, 2021
ea80373
AssertionFinder refactor
orklah Sep 4, 2021
ba7f2a5
allow range int to be positive
orklah Sep 4, 2021
cc6ab83
improve type when min = max and add test
orklah Sep 15, 2021
c4b47d3
activate arithmetic operations on func calls
orklah Sep 15, 2021
a70e703
activate arithmetic operations on method calls too
orklah Sep 15, 2021
c694976
activate arithmetic operations on properties too
orklah Sep 15, 2021
5ec9e65
try with everything except Variables
orklah Sep 15, 2021
efde3f9
change order for better diff
orklah Sep 20, 2021
2b56d52
rename vars for better diff
orklah Sep 20, 2021
012b65d
try to improve behaviour
orklah Sep 20, 2021
d3d1147
allow arithmetics on variables as long as we're out of loops
orklah Sep 20, 2021
a54e76c
add new issues to baseline and fix a test
orklah Sep 20, 2021
e6ba609
turn inside_loop to true for do...while
orklah Sep 20, 2021
85d65d3
restrict the test because int size is fixed on runtime environment
orklah Sep 20, 2021
b542daf
more precise test
orklah Sep 20, 2021
c9db2df
Merge branch 'master' of https://github.com/gmessier/psalm into advan…
gmessier Sep 24, 2021
97e91e6
code trimming
orklah Sep 25, 2021
f86e3b1
Merge pull request #6532 from orklah/code-trimming
orklah Sep 25, 2021
a92fee8
better combining
orklah Sep 25, 2021
9c65953
Merge pull request #6533 from orklah/combineTypes
orklah Sep 25, 2021
3e6bf6f
remove unused nullable on param types
orklah Sep 25, 2021
056f85b
undefined property
orklah Sep 25, 2021
0780b85
undefined param
orklah Sep 25, 2021
ddcd2e6
undefined param
orklah Sep 25, 2021
56dcfe8
weird syntax + class-string param
orklah Sep 25, 2021
f279f6c
Merge pull request #6534 from orklah/restr-types
orklah Sep 25, 2021
1f2316f
polymorphism
orklah Sep 25, 2021
2f82f25
undefined param
orklah Sep 25, 2021
b4e0f83
unparsable types
orklah Sep 25, 2021
e61d490
missing return
orklah Sep 25, 2021
ebef0de
missing variable
orklah Sep 25, 2021
06f497f
missing return
orklah Sep 25, 2021
7b1ee09
unnecessary phpdoc
orklah Sep 25, 2021
04afe1f
improved assertion
orklah Sep 25, 2021
a865090
missing types
orklah Sep 25, 2021
f0b0540
unparsable types
orklah Sep 25, 2021
671a175
unnecessary phpdoc
orklah Sep 25, 2021
a9b1248
unnecessary phpdoc is necessary
orklah Sep 25, 2021
89f5c12
unparsable types
orklah Sep 25, 2021
748d58a
unparsable types
orklah Sep 25, 2021
cc77aba
unparsable types
orklah Sep 25, 2021
7891e61
unparsable types
orklah Sep 25, 2021
146d02e
unset instead of reassign
orklah Sep 25, 2021
bff0867
put int instead of float
orklah Sep 25, 2021
6c89212
interface compat
orklah Sep 25, 2021
7447489
better types
orklah Sep 25, 2021
06da968
interface compat
orklah Sep 25, 2021
41ea541
unset instead of reassign
orklah Sep 25, 2021
f1e5ecf
CS fix
orklah Sep 25, 2021
f4fa1f7
CS fix
orklah Sep 25, 2021
a214b14
CS fix
orklah Sep 25, 2021
afbda6d
Merge pull request #6535 from orklah/SA
orklah Sep 25, 2021
966211e
unused variable
orklah Sep 26, 2021
a03e55a
array_push misused
orklah Sep 26, 2021
c0f6474
merging exceptions
orklah Sep 26, 2021
4481428
unused param
orklah Sep 26, 2021
153de33
weird param always false
orklah Sep 26, 2021
b65af9b
static in final class
orklah Sep 26, 2021
fce60a0
param defaults
orklah Sep 26, 2021
c45e9bf
useless switch
orklah Sep 26, 2021
5b68430
unnecessary ternary
orklah Sep 26, 2021
5777d02
missing types
orklah Sep 26, 2021
be84062
unnecessary return
orklah Sep 26, 2021
a5aa824
unnecessary local variable
orklah Sep 26, 2021
6dd1e19
unnecessary ref
orklah Sep 26, 2021
dae29c8
missing visibility
orklah Sep 26, 2021
ae1afd9
coalesce operator
orklah Sep 26, 2021
a85cba3
dead code
orklah Sep 26, 2021
998f91a
variable with single value
orklah Sep 26, 2021
c11b32d
redundant variable check
orklah Sep 26, 2021
ddf7491
if with common parts
orklah Sep 26, 2021
53e4719
boolean cast
orklah Sep 26, 2021
a95cb15
no need for parent
orklah Sep 26, 2021
18b0c63
shorter operations
orklah Sep 26, 2021
46801c4
clearer string operations
orklah Sep 26, 2021
f788fec
static::class
orklah Sep 26, 2021
72eab30
coalesce operator
orklah Sep 26, 2021
2315316
return types
orklah Sep 26, 2021
9170b0a
replace list()
orklah Sep 26, 2021
c91bdfb
old casts
orklah Sep 26, 2021
4577a11
imports
orklah Sep 26, 2021
5d6d3df
unnecessary identical child method
orklah Sep 26, 2021
db395d5
unnecessary cast
orklah Sep 26, 2021
38dac34
unnecessary null initialization
orklah Sep 26, 2021
ab6efe4
fix CS
orklah Sep 26, 2021
b29737f
Merge pull request #6536 from orklah/cleanup2
orklah Sep 26, 2021
51333e8
[TASK] Resolve namespace of class related AST statements
ohader Jan 23, 2021
76dade4
Prevent unnecessary filter_var() warning
mmcev106 Sep 27, 2021
79340b4
Prevent unnecessary filter_var() warnings
mmcev106 Sep 27, 2021
ef82910
Merge pull request #6537 from mmcev106/master
orklah Sep 27, 2021
caf4d57
enable test on taint
orklah Sep 27, 2021
9d9dba1
Merge pull request #6538 from orklah/taint-windows
orklah Sep 27, 2021
e1727ff
Update XlsWriter signatures
pawel-slowik Sep 28, 2021
096a6db
Remove undocumented / untested XlsWriter methods
pawel-slowik Sep 28, 2021
5ac21dd
Merge pull request #6545 from pawel-slowik/update-xlswriter-signatures
orklah Sep 28, 2021
5a99c9b
offset the starting position of the function in case of attributes
orklah Sep 29, 2021
2a2e7c5
prevent object leaking that lead to changes in callmap
orklah Sep 29, 2021
3133cd1
fix NPE
orklah Sep 29, 2021
4c6f438
fix test
orklah Sep 29, 2021
4f5e30f
Use correct English articles
simPod Sep 30, 2021
02ef33c
Merge pull request #6554 from simPod/use-a
orklah Sep 30, 2021
31763b3
Fix fopen
vjik Sep 30, 2021
10f1af1
Merge pull request #6557 from vjik/fix
orklah Sep 30, 2021
843f14d
fix 'Undefined offset: 1' in CodeBase::getTypeContextAtPosition issue…
MykolaZhebet Sep 30, 2021
f94be52
Merge pull request #6560 from NikolayZhebet/fix-codebase-pls-undefine…
weirdan Sep 30, 2021
d232cc0
Merge pull request #6553 from orklah/exec-leak
weirdan Sep 30, 2021
377d3bd
Merge pull request #6552 from orklah/manipulator
weirdan Sep 30, 2021
97a3d67
Merge pull request #5091 from ohader/namespace-resolver
weirdan Sep 30, 2021
2e7e343
Merge pull request #6423 from orklah/count-equal-0-negated-assertion
weirdan Oct 1, 2021
83ad836
assert both sides of an equality
orklah Sep 11, 2021
7f0d253
add comment
orklah Sep 12, 2021
7e1c66d
add limit to the number of clauses simplifyCNF can handle
orklah Sep 26, 2021
b9f14f8
improve min/max inference, add a return type provider for rand, mt_ra…
orklah Aug 20, 2021
f8c2a89
use Int ranges to describe offset after array_fill when both args are…
orklah Sep 13, 2021
dd5c290
fix error on continue
orklah Sep 22, 2021
597e9a9
Makes BooleanNot smarter
orklah Sep 22, 2021
85f16e9
handle the case where analysis failed
orklah Sep 22, 2021
b9e65f0
refactor paradoxical conditions
orklah Sep 22, 2021
0f6d271
possibly undefined unions can't be truthy
orklah Sep 22, 2021
f8628ef
fix errors
orklah Sep 22, 2021
532aa90
add and fix tests
orklah Sep 22, 2021
2df1f9d
add resource to truthy types
orklah Sep 22, 2021
b14fccb
refine types in Always methods
orklah Sep 22, 2021
28edc25
fix doc
orklah Sep 22, 2021
f641d9e
assert that some type is a list
orklah Sep 14, 2021
e02eec9
refactor Assertions for is_ functions
orklah Sep 16, 2021
fa9990a
fix wrong method name
orklah Sep 16, 2021
0b8681c
check namespace before adding assertions
orklah Sep 16, 2021
ee4dbaf
fix test
orklah Sep 16, 2021
e0b2cb5
consistency
orklah Sep 17, 2021
d3bc179
cover the case where the call to the function is namespaced but the f…
orklah Sep 19, 2021
5efd49f
fix redundant condition
orklah Oct 2, 2021
518e18f
Convert finfo functions to use object instead of a resource
tomasnorre Oct 2, 2021
232ebb7
Convert imap functions to use object instead of a resource
tomasnorre Oct 2, 2021
c052c30
Add CURLStringFile class
ishanvyas22 Oct 3, 2021
75755ac
Add CURLStringFile in classmap delta
ishanvyas22 Oct 3, 2021
5266114
chore: make mime field optional
ishanvyas22 Oct 3, 2021
79270c0
chore: make changes in CallMap.php file
ishanvyas22 Oct 3, 2021
48dade5
fix: phpstub not needed
ishanvyas22 Oct 3, 2021
8360f0b
Merge pull request #6574 from ishanvyas22/add-CURLStringFile-class
orklah Oct 3, 2021
53c0a4e
cleanup
orklah Oct 3, 2021
430fd61
cleanup
orklah Oct 3, 2021
1e70be9
fix wrong operator priority
orklah Oct 3, 2021
246f817
Merge pull request #6566 from tomasnorre/fileinfo-resource-to-object
orklah Oct 3, 2021
73495d7
Merge pull request #6567 from tomasnorre/imap-rosource-to-object
orklah Oct 3, 2021
aba9541
Psalter add psalm-param modifying
orklah Oct 3, 2021
4f696ec
add/fix tests
orklah Oct 3, 2021
af8033a
Merge pull request #6577 from orklah/cleanup3
orklah Oct 3, 2021
fffe642
fix tests
orklah Oct 3, 2021
942b3b6
Merge pull request #6522 from MorrisJobke/fix/show-file-and-line-in-e…
orklah Oct 4, 2021
8660f68
Merge pull request #6519 from gmessier/advanced-issue-handlers
orklah Oct 4, 2021
9dc151a
Merge pull request #6516 from gmessier/hotfix/gmessier-xml-include
orklah Oct 4, 2021
8b07e69
Merge pull request #6514 from zoonru/if-this-is
orklah Oct 4, 2021
66206bf
fix wrong type description added in signature
orklah Oct 4, 2021
993349d
Convert LDAP resources to objects
tomasnorre Oct 2, 2021
a49ff46
Update typo in PHP81.phpstub
tomasnorre Oct 3, 2021
4b8f212
Fix incorrect parameters names
tomasnorre Oct 3, 2021
96d42b6
Merge pull request #6570 from tomasnorre/ldap-resources-to-objects
orklah Oct 4, 2021
b0842c6
Merge pull request #6475 from orklah/range6
orklah Oct 4, 2021
0e83afd
Merge pull request #6518 from orklah/fix-truthy
orklah Oct 4, 2021
ac6a75e
Merge pull request #6473 from orklah/double-assert2
orklah Oct 4, 2021
2c72854
Merge pull request #6485 from orklah/list-assert
orklah Oct 4, 2021
960af95
Convert PSpell resources to objects
tomasnorre Oct 4, 2021
213644d
Merge pull request #6569 from tomasnorre/pspell-resources-to-objects
orklah Oct 4, 2021
f03f362
Declare `html-escaped-string` is deprecated on doc
sasezaki Oct 4, 2021
c7fd665
Merge pull request #6576 from orklah/wrong_priority
orklah Oct 4, 2021
d22105d
Merge pull request #6580 from orklah/psalter-generic-object-tophpstring
orklah Oct 4, 2021
f328610
Update docs/annotating_code/type_syntax/scalar_types.md
weirdan Oct 4, 2021
20bb5f1
fix isAlwaysTruthy: TNonEmptyString can be falsy (with '0')
orklah Oct 4, 2021
7332c51
Merge pull request #6582 from sasezaki/patch-1
weirdan Oct 4, 2021
12ecaaa
makes Psalm understand templates in lhs
orklah Oct 5, 2021
3cf5dc5
makes Psalm understand templates in lhs
orklah Oct 5, 2021
96ed252
Merge pull request #6589 from orklah/strict-callable
orklah Oct 5, 2021
2956220
Merge pull request #6585 from orklah/truthy
orklah Oct 5, 2021
902206b
Merge pull request #6578 from orklah/psalter-psalm-param
orklah Oct 5, 2021
7321eed
don't add return type if it's the same than signature unless there is…
orklah Oct 5, 2021
13c2ba6
fix tests
orklah Oct 5, 2021
dbc7090
fix tests
orklah Oct 5, 2021
1a2ac65
Merge pull request #6590 from orklah/redundant-return-type
orklah Oct 5, 2021
d561b29
ReflectionClass::getReflectionConstants has a filter parameter
vaceletm Oct 5, 2021
014543b
Fix invalid class/method declaration in stub
sasezaki Oct 5, 2021
1a3d360
Add test to verify that CallMap is OK
vaceletm Oct 5, 2021
fffe2b2
Remove sample test case
vaceletm Oct 5, 2021
d0df1a6
Merge pull request #6592 from sasezaki/stub_spl_abstract_cannot_contain
orklah Oct 5, 2021
4334742
revert confusing change
orklah Oct 5, 2021
d8f42d7
Merge pull request #6597 from orklah/fix-errors
orklah Oct 5, 2021
77c70c0
allow |false in unions as long as it's not alone and not with null
orklah Oct 5, 2021
ecb541e
add test
orklah Oct 5, 2021
0f275cb
Merge pull request #6594 from orklah/falsable-returns
orklah Oct 5, 2021
ad6229f
fix error
orklah Oct 5, 2021
4ca1710
Merge pull request #6598 from orklah/fix-error
orklah Oct 5, 2021
e046732
Merge pull request #6591 from vaceletm/fix-6588-reflection
orklah Oct 5, 2021
fbdb4de
Update output provider to differentiate SonarSource products
nils-werner-sonarsource Jul 26, 2021
e291c03
Fix typo
nils-werner-sonarsource Jul 26, 2021
874d94f
Reduce report providers to a common SonarSourceReport class
nils-werner-sonarsource Jul 27, 2021
3aedb12
Fix code quality issues
nils-werner-sonarsource Oct 7, 2021
48ffba6
Add suggested documentation to ReportOutputTest
nils-werner-sonarsource Oct 8, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
61 changes: 3 additions & 58 deletions .appveyor.yml
Original file line number Diff line number Diff line change
@@ -1,59 +1,4 @@
build: false
platform:
- x64

clone_folder: c:\projects\php-project-workspace

## Set up environment variables
init:
- SET PATH=C:\Program Files\OpenSSL;c:\tools\php;%PATH%
- SET COMPOSER_NO_INTERACTION=1
- SET PHP=1 # This var is connected to PHP install cache
- SET ANSICON=121x90 (121x90)

environment:
SSL_CERT_FILE: "C:\\tools\\php\\cacert.pem"
matrix:
- php_ver_target: 8.0
DEPS: 'high'

cache:
- '%LOCALAPPDATA%\Composer\files'
- '%LOCALAPPDATA%\Composer\vcs'
# Cache chocolatey packages
- C:\ProgramData\chocolatey\bin
- C:\ProgramData\chocolatey\lib
# Cache php install
- c:\tools\php

## Install PHP and composer, and run the appropriate composer command
install:
- IF EXIST c:\tools\php (SET PHP=0) # Checks for the PHP install being cached
- ps: appveyor-retry cinst --no-progress --params '""/InstallDir:C:\tools\php""' --ignore-checksums -y php --version ((choco search php --exact --all-versions -r | select-string -pattern $env:php_ver_target | sort { [version]($_ -split '\|' | select -last 1) } -Descending | Select-Object -first 1) -replace '[php|]','')
- appveyor DownloadFile https://curl.haxx.se/ca/cacert.pem -FileName C:\tools\php\cacert.pem
- cd c:\tools\php
- IF %PHP%==1 copy php.ini-production php.ini /Y
- IF %PHP%==1 echo date.timezone="UTC" >> php.ini
- IF %PHP%==1 echo extension_dir=ext >> php.ini
- IF %PHP%==1 echo extension=php_curl.dll >> php.ini
- IF NOT EXIST php-installed.txt echo curl.cainfo="C:/tools/php/cacert.pem" >> php.ini
- IF NOT EXIST php-installed.txt echo openssl.cafile="C:/tools/php/cacert.pem" >> php.ini
- IF %PHP%==1 echo extension=php_openssl.dll >> php.ini
- IF %PHP%==1 echo extension=php_mbstring.dll >> php.ini
- IF %PHP%==1 echo extension=php_fileinfo.dll >> php.ini
- IF %PHP%==1 echo zend.assertions=1 >> php.ini
- IF %PHP%==1 echo assert.exception=On >> php.ini
- IF %PHP%==1 echo error_reporting=E_ALL >> php.ini
- IF %PHP%==1 echo @php %%~dp0composer.phar %%* > composer.bat
- IF NOT EXIST composer.phar appveyor-retry appveyor DownloadFile https://getcomposer.org/composer-stable.phar -FileName composer.phar
- cd c:\projects\php-project-workspace
- php -r "phpinfo(INFO_GENERAL);"
- if NOT DEFINED APPVEYOR_REPO_TAG_NAME (set COMPOSER_ROOT_VERSION=dev-master)
- if %DEPS%==low appveyor-retry composer update --no-interaction --no-progress --profile --prefer-lowest --prefer-stable
- if %DEPS%==high appveyor-retry composer update --no-interaction --no-progress --profile

## Run the actual test
test_script:
- cd c:\projects\php-project-workspace
- vendor/bin/paratest --log-junit build/phpunit/phpunit.xml
- php ./psalm --shepherd
branches:
only:
- dear-appveyor-please-dont-build-this-repo
50 changes: 50 additions & 0 deletions .github/workflows/windows-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
name: Run unit tests on Windows

on: [push, pull_request]

jobs:
tests:
name: "Unit Tests"

runs-on: windows-latest

strategy:
fail-fast: false

steps:
- name: Set git to use LF
run: |
git config --global core.autocrlf false
git config --global core.eol lf

- name: Set up PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.0'
tools: composer:v2

- uses: actions/checkout@v2

- name: Get Composer Cache Directories
id: composer-cache
run: |
echo "::set-output name=files_cache::$(composer config cache-files-dir)"
echo "::set-output name=vcs_cache::$(composer config cache-vcs-dir)"

- name: Cache composer cache
uses: actions/cache@v2
with:
path: |
${{ steps.composer-cache.outputs.files_cache }}
${{ steps.composer-cache.outputs.vcs_cache }}
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
restore-keys: |
${{ runner.os }}-composer-

- name: Run composer install
run: composer install -o
env:
COMPOSER_ROOT_VERSION: dev-master

- name: Run unit tests
run: vendor/bin/paratest --log-junit build/phpunit/phpunit.xml
1 change: 1 addition & 0 deletions bin/github-deploy-phar.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ git commit -m "Updated Psalm phar to commit ${GITHUB_SHA}"
git push origin master

tag=${GITHUB_REF/refs\/heads\//}
tag=${tag/refs\/tags\//}

if [[ "$tag" != 'master' ]] ; then
git tag "$tag"
Expand Down
6 changes: 3 additions & 3 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,12 @@
"require": {
"php": "^7.1|^8",
"ext-SimpleXML": "*",
"ext-ctype": "*",
"ext-dom": "*",
"ext-json": "*",
"ext-libxml": "*",
"ext-tokenizer": "*",
"ext-mbstring": "*",
"ext-tokenizer": "*",
"amphp/amp": "^2.4.2",
"amphp/byte-stream": "^1.5",
"composer/package-versions-deprecated": "^1.8.0",
Expand All @@ -30,7 +31,7 @@
"felixfbecker/advanced-json-rpc": "^3.0.3",
"felixfbecker/language-server-protocol": "^1.5",
"netresearch/jsonmapper": "^1.0 || ^2.0 || ^3.0 || ^4.0",
"nikic/php-parser": "^4.12",
"nikic/php-parser": "4.12.*",
"openlss/lib-array2xml": "^1.0",
"sebastian/diff": "^3.0 || ^4.0",
"symfony/console": "^3.4.17 || ^4.1.6 || ^5.0",
Expand All @@ -52,7 +53,6 @@
"slevomat/coding-standard": "^7.0",
"squizlabs/php_codesniffer": "^3.5",
"symfony/process": "^4.3 || ^5.0",
"weirdan/phpunit-appveyor-reporter": "^1.0.0",
"weirdan/prophecy-shim": "^1.0 || ^2.0"
},
"suggest": {
Expand Down
34 changes: 19 additions & 15 deletions config.xsd
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
targetNamespace="https://getpsalm.org/schema/config"
elementFormDefault="qualified"
>
<xs:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="http://www.w3.org/2001/03/xml.xsd" />
<xs:element name="psalm" type="PsalmType" />

<xs:complexType name="PsalmType">
Expand Down Expand Up @@ -98,19 +97,19 @@
<xs:element name="file" minOccurs="0" maxOccurs="unbounded" type="NameAttributeType" />
<xs:element name="ignoreFiles" minOccurs="0" maxOccurs="1" type="IgnoreFilesType" />
</xs:choice>
<xs:attribute ref="xml:base" />
<xs:anyAttribute processContents="skip"/>
</xs:complexType>

<xs:complexType name="TaintAnalysisType">
<xs:choice maxOccurs="unbounded">
<xs:element name="ignoreFiles" minOccurs="0" maxOccurs="1" type="IgnoreFilesType" />
</xs:choice>
<xs:attribute ref="xml:base" />
<xs:anyAttribute processContents="skip"/>
</xs:complexType>

<xs:complexType name="NameAttributeType">
<xs:attribute ref="xml:base" />
<xs:attribute name="name" type="xs:string" use="required" />
<xs:anyAttribute processContents="skip"/>
</xs:complexType>

<xs:complexType name="StubsAttributeType">
Expand All @@ -125,14 +124,14 @@
</xs:choice>

<xs:attribute name="allowMissingFiles" type="xs:string" />
<xs:attribute ref="xml:base" />
<xs:anyAttribute processContents="skip"/>
</xs:complexType>

<xs:complexType name="ProjectDirectoryAttributeType">
<xs:attribute name="name" type="xs:string" use="required" />
<xs:attribute name="ignoreTypeStats" type="xs:string" />
<xs:attribute name="useStrictTypes" type="xs:string" />
<xs:attribute ref="xml:base" />
<xs:anyAttribute processContents="skip"/>
</xs:complexType>

<xs:complexType name="FileExtensionsType">
Expand All @@ -145,43 +144,43 @@
</xs:complexType>
</xs:element>
</xs:sequence>
<xs:attribute ref="xml:base" />
<xs:anyAttribute processContents="skip"/>
</xs:complexType>

<xs:complexType name="MockClassesType">
<xs:sequence>
<xs:element name="class" maxOccurs="unbounded" type="NameAttributeType" />
</xs:sequence>
<xs:attribute ref="xml:base" />
<xs:anyAttribute processContents="skip"/>
</xs:complexType>

<xs:complexType name="UniversalObjectCratesType">
<xs:sequence>
<xs:element name="class" maxOccurs="unbounded" type="NameAttributeType" />
</xs:sequence>
<xs:attribute ref="xml:base" />
<xs:anyAttribute processContents="skip"/>
</xs:complexType>

<xs:complexType name="ExceptionsType">
<xs:sequence>
<xs:element name="class" minOccurs="0" maxOccurs="unbounded" type="ExceptionType" />
<xs:element name="classAndDescendants" minOccurs="0" maxOccurs="unbounded" type="ExceptionType" />
</xs:sequence>
<xs:attribute ref="xml:base" />
<xs:anyAttribute processContents="skip"/>
</xs:complexType>

<xs:complexType name="StubsType">
<xs:sequence>
<xs:element name="file" maxOccurs="unbounded" type="StubsAttributeType" />
</xs:sequence>
<xs:attribute ref="xml:base" />
<xs:anyAttribute processContents="skip"/>
</xs:complexType>

<xs:complexType name="ExitFunctionsType">
<xs:sequence>
<xs:element name="function" maxOccurs="unbounded" type="NameAttributeType" />
</xs:sequence>
<xs:attribute ref="xml:base" />
<xs:anyAttribute processContents="skip"/>
</xs:complexType>

<xs:complexType name="PluginsType">
Expand All @@ -200,7 +199,7 @@
</xs:complexType>
</xs:element>
</xs:choice>
<xs:attribute ref="xml:base" />
<xs:anyAttribute/>
</xs:complexType>

<xs:complexType name="IssueHandlersType">
Expand All @@ -227,6 +226,8 @@
<xs:element name="DocblockTypeContradiction" type="IssueHandlerType" minOccurs="0" />
<xs:element name="DuplicateArrayKey" type="IssueHandlerType" minOccurs="0" />
<xs:element name="DuplicateClass" type="IssueHandlerType" minOccurs="0" />
<xs:element name="DuplicateEnumCase" type="ClassIssueHandlerType" minOccurs="0" />
<xs:element name="DuplicateEnumCaseValue" type="ClassIssueHandlerType" minOccurs="0" />
<xs:element name="DuplicateFunction" type="IssueHandlerType" minOccurs="0" />
<xs:element name="DuplicateMethod" type="MethodIssueHandlerType" minOccurs="0" />
<xs:element name="DuplicateParam" type="IssueHandlerType" minOccurs="0" />
Expand All @@ -236,6 +237,7 @@
<xs:element name="FalseOperand" type="IssueHandlerType" minOccurs="0" />
<xs:element name="ForbiddenCode" type="IssueHandlerType" minOccurs="0" />
<xs:element name="ForbiddenEcho" type="IssueHandlerType" minOccurs="0" />
<xs:element name="IfThisIsMismatch" type="IssueHandlerType" minOccurs="0" />
<xs:element name="ImplementationRequirementViolation" type="IssueHandlerType" minOccurs="0" />
<xs:element name="ImplementedParamTypeMismatch" type="IssueHandlerType" minOccurs="0" />
<xs:element name="ImplementedReturnTypeMismatch" type="IssueHandlerType" minOccurs="0" />
Expand Down Expand Up @@ -266,6 +268,8 @@
<xs:element name="InvalidClone" type="IssueHandlerType" minOccurs="0" />
<xs:element name="InvalidDocblock" type="IssueHandlerType" minOccurs="0" />
<xs:element name="InvalidDocblockParamName" type="IssueHandlerType" minOccurs="0" />
<xs:element name="InvalidEnumBackingType" type="ClassIssueHandlerType" minOccurs="0" />
<xs:element name="InvalidEnumCaseValue" type="ClassIssueHandlerType" minOccurs="0" />
<xs:element name="InvalidExtendClass" type="ClassIssueHandlerType" minOccurs="0" />
<xs:element name="InvalidFalsableReturnType" type="IssueHandlerType" minOccurs="0" />
<xs:element name="InvalidFunctionCall" type="IssueHandlerType" minOccurs="0" />
Expand Down Expand Up @@ -477,7 +481,7 @@
<xs:element name="UnusedReturnValue" type="IssueHandlerType" minOccurs="0" />
<xs:element name="UnusedVariable" type="IssueHandlerType" minOccurs="0" />
</xs:choice>
<xs:attribute ref="xml:base" />
<xs:anyAttribute/>
</xs:complexType>

<xs:complexType name="IssueHandlerType">
Expand Down Expand Up @@ -627,7 +631,7 @@
<xs:sequence>
<xs:element name="var" maxOccurs="unbounded" type="IdentifierType" />
</xs:sequence>
<xs:attribute ref="xml:base" />
<xs:anyAttribute/>
</xs:complexType>

<xs:complexType name="IdentifierType">
Expand Down
Loading