Skip to content

Commit

Permalink
phpunit fixes + fix nasty bug with phpstanTestcase unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
henzeb committed Feb 5, 2023
1 parent 439a5ca commit a446c08
Show file tree
Hide file tree
Showing 20 changed files with 842 additions and 64 deletions.
11 changes: 8 additions & 3 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ jobs:
strategy:
fail-fast: true
matrix:
php: ['8.1','8.2']
stability: [prefer-lowest, prefer-stable]
php: [ '8.1','8.2' ]
stability: [ prefer-lowest, prefer-stable ]

steps:
- name: Checkout Code
Expand Down Expand Up @@ -59,7 +59,12 @@ jobs:
command: composer update --${{ matrix.stability }} --prefer-dist --no-interaction --no-progress --quiet

- name: Execute PHPUnit
run: vendor/bin/phpunit
if: ${{ !env.CC_TOKEN || (matrix.stability != 'prefer-stable' && matrix.php != '8.2') }}

- name: Execute PHPUnit for codeclimate
run: vendor/bin/phpunit --coverage-clover=coverage.xml
if: ${{ env.CC_TOKEN && matrix.stability == 'prefer-stable' && matrix.php == '8.2' }}

- name: Upload coverage to codeclimate
uses: paambaati/codeclimate-action@v3.1.1
Expand All @@ -69,4 +74,4 @@ jobs:
with:
coverageCommand: ''
coverageLocations: ./coverage.xml:clover
if: ${{ !env.ACT && env.CC_TOKEN && matrix.stability == 'prefer-stable' && matrix.php == '8.2' }}
if: ${{ env.CC_TOKEN && matrix.stability == 'prefer-stable' && matrix.php == '8.2' }}
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
.phpunit.result.cache
build
coverage
coverage.xml
composer.lock
testbench.yaml
vendor
Expand Down
Loading

0 comments on commit a446c08

Please sign in to comment.