docs: ✏️ update readme #50
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: CI | |
on: | |
push: | |
paths-ignore: | |
- docs/** | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: shivammathur/setup-php@v2 | |
with: | |
php-version: 8.3 | |
extensions: mbstring, pcov | |
- uses: actions/checkout@v4 | |
- name: Get Composer cache directory path | |
id: composer-cache-dir-path | |
run: echo "path=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT | |
- name: Cache Composer dependencies | |
uses: actions/cache@v4 | |
with: | |
path: ${{ steps.composer-cache-dir-path.outputs.path }} | |
key: ${{ runner.os }}-composer-${{ hashFiles('composer.lock') }} | |
restore-keys: ${{ runner.os }}-composer- | |
- name: Install Composer Dependencies | |
run: | | |
composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist | |
composer bin all install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist | |
- name: Execute tests | |
run: composer tests | |
- name: Generate coverage report | |
run: composer pcov | |
- name: Upload coverage report to Codecov | |
uses: codecov/codecov-action@v4 | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
files: build/coverage.xml | |
verbose: true |