Skip to content

Replace the coverage badge #4

Replace the coverage badge

Replace the coverage badge #4

Workflow file for this run

name: CI
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
coverage:
name: Code Coverage - PHPP ${{ matrix.php-versions }} on ${{ matrix.operating-system }}
runs-on: ${{ matrix.operating-system }}
if: "!contains(github.event.head_commit.message, '[ci]')"
strategy:
matrix:
operating-system: ['ubuntu-latest']
php-versions: ['8.4']
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-versions }}
extensions: mbstring, intl, sodium, xdebug
ini-values: error_reporting=-1, display_errors=On
coverage: none
- name: Install Composer dependencies
uses: "ramsey/composer-install@v3"
- name: PHPUnit tests
run: vendor/bin/phpunit --coverage-clover clover.xml
- name: phpunit-coverage-badge
uses: timkrase/phpunit-coverage-badge@v1.2.1
with:
coverage_badge_path: .github/coverage.svg
push_badge: false
- name: Git push to image-data branch
uses: peaceiris/actions-gh-pages@v3
with:
publish_dir: .github
publish_branch: image-data
github_token: ${{ secrets.GITHUB_TOKEN }}
user_name: 'github-actions[bot]'
user_email: 'github-actions[bot]@users.noreply.github.com'