Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
SimonvanWijhe committed Jun 12, 2024
1 parent a291070 commit 81fc44d
Showing 1 changed file with 18 additions and 4 deletions.
22 changes: 18 additions & 4 deletions .github/workflows/test-coverage.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
name: PhpUnit Coverage Badge

on: pull_request
on: push

jobs:
coverage:
name: Test Coverage
test:
name: Run tests
runs-on: ubuntu-latest

steps:
Expand All @@ -14,12 +14,26 @@ jobs:
- name: Setup PHP
uses: shivammathur/setup-php@2.9.0
with:
php-version: '8.1'
php-version: '7.4'
extensions: simplexml, dom, xml, xdebug, intl

- name: Get composer cache directory
id: composer-cache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"

- name: Cache dependencies
uses: actions/cache@v2
with:
path: ${{ steps.composer-cache.outputs.dir }}
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
restore-keys: ${{ runner.os }}-composer-

- name: Install dependencies
run: composer install --prefer-dist

- name: Recreate autoload file
run: composer dump-autoload

- name: Run Unit Tests
run: XDEBUG_MODE_COVERAGE=coverage vendor/bin/pest

Expand Down

0 comments on commit 81fc44d

Please sign in to comment.