1717 - name : Install PHP
1818 uses : shivammathur/setup-php@v2
1919 with :
20- php-version : ' 7.4 '
20+ php-version : ' 8.1 '
2121 coverage : ' none'
2222 - name : Cache dependencies
2323 uses : actions/cache@v3
5252 - " "
5353 include :
5454 - os : windows-latest
55- php_version : 8.0
55+ php_version : 8.1
5656 dependencies_level : --prefer-lowest
57+ - os : windows-latest
58+ php_version : 8.1
59+ dependencies_level : ' '
5760 runs-on : ${{ matrix.os }}
5861 steps :
5962 - name : Set git to use LF on windows
@@ -76,22 +79,14 @@ jobs:
7679 key : " cache-composer-${{ hashFiles('composer.json') }}"
7780 restore-keys : ' cache-composer-'
7881 - name : Run composer
79- if : ${{ matrix.php_version != '8.0' && matrix.php_version != '8.1' && matrix.php_version != '8.2' && matrix.php_version != '8.3' }}
8082 run : composer update ${{ matrix.dependencies_level }} --prefer-dist --no-interaction --no-progress
81- - name : Run composer with workaround for PHP 8 and incompatible PHPUnit
82- if : ${{ matrix.php_version == '8.0' || matrix.php_version == '8.1' || matrix.php_version == '8.2' || matrix.php_version == '8.3' }}
83- run : composer update ${{ matrix.dependencies_level }} --ignore-platform-reqs --prefer-dist --no-interaction --no-progress
8483 - name : Check composer.json
8584 run : composer normalize --dry-run
8685 - name : Run tests with coverage
87- if : ${{ matrix.php_version != '8.0 ' && matrix.php_version != '8.1' && matrix.php_version != '8.2' && matrix.php_version != '8.3 ' }}
86+ if : ${{ matrix.os != 'windows-latest ' && matrix.php_version == '8.1' && matrix.dependencies_level != '--prefer-lowest ' }}
8887 run : php vendor/bin/phpunit --coverage-clover=coverage.xml
8988 - name : Run tests
90- if : ${{ matrix.php_version == '8.0' }}
9189 run : vendor/bin/phpunit
92- - name : Run tests
93- if : ${{ matrix.php_version == '8.1' }}
94- run : vendor/bin/phpunit --no-configuration --bootstrap=tests/bootstrap.php --dont-report-useless-tests vendor/squizlabs/php_codesniffer/tests/Standards/AllSniffs.php
9590 - name : Run integration tests
9691 run : vendor/bin/phpcs -s --standard=MO4 integrationtests/testfile.php
9792 - name : Run PHPStan
0 commit comments