No -v
for phpunit
#59
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Code Coverage | |
on: | |
push: | |
branches: | |
- main | |
- master | |
jobs: | |
coverage: | |
runs-on: ubuntu-latest | |
name: Publish code coverage | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Setup PHP | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: 8.3 | |
extensions: dom, curl, libxml, mbstring, zip, pcntl, bcmath, intl, iconv | |
coverage: pcov | |
- name: Cache dependencies | |
uses: actions/cache@v2 | |
with: | |
path: | | |
vendor | |
${{ steps.composer-cache-files-dir.outputs.dir }} | |
key: ${{ runner.os }}-composer-${{ hashFiles('composer.json') }} | |
restore-keys: | | |
${{ runner.os }}-composer- | |
- name: Install dependencies | |
env: | |
COMPOSER_DISCARD_CHANGES: true | |
run: composer require --no-suggest --no-progress --no-interaction --prefer-dist --update-with-all-dependencies "laravel/framework:^11.0" "orchestra/testbench:9.x-dev" | |
- name: Run and publish code coverage | |
uses: paambaati/[email protected] | |
env: | |
CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }} | |
with: | |
coverageCommand: vendor/bin/phpunit --coverage-clover ${{ github.workspace }}/clover.xml | |
debug: true | |
coverageLocations: | |
"${{github.workspace}}/clover.xml:clover" |