From 046a6e2bdddf04afeacbc35123c791f1d66b2877 Mon Sep 17 00:00:00 2001 From: Peter Elmered Date: Wed, 6 Nov 2024 18:15:02 +0100 Subject: [PATCH] Add type coverage check --- .github/workflows/tests.yml | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index d9b5a5b..04a4dad 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -55,19 +55,17 @@ jobs: php-version: 8.3 extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv, imagick, fileinfo coverage: pcov + - name: Install dependencies run: composer update --prefer-stable --prefer-dist --no-interaction + - name: Execute tests - run: vendor/bin/phpunit --coverage-clover=build/logs/clover.xml -# - name: Execute type coverage tests -# run: vendor/bin/pest --type-coverage --type-coverage-json=build/logs/pest-coverage.json + run: vendor/bin/phpunit --coverage-clover=reports/coverage/clover.xml - - name: Upload Test Coverage + - name: Execute type coverage tests + run: vendor/bin/pest --type-coverage --type-coverage-json=reports/coverage/pest-types-coverage.json + + - name: Upload Coverage Reports env: OTTERWISE_TOKEN: ${{ secrets.OTTERWISE_TOKEN }} - run: bash <(curl -s https://raw.githubusercontent.com/getOtterWise/bash-uploader/main/uploader.sh) - -# - name: Upload Types Coverage -# env: -# OTTERWISE_TOKEN: ${{ secrets.OTTERWISE_TOKEN }} -# run: bash <(curl -s https://raw.githubusercontent.com/getOtterWise/bash-uploader/main/uploader.sh) --type-coverage-file build/logs/pest-coverage.json + run: bash <(curl -s https://raw.githubusercontent.com/getOtterWise/bash-uploader/main/uploader.sh) --file reports/coverage/test-coverage-clover.xml --type-coverage-file reports/coverage/pest-types-coverage.json