Skip to content

Commit 564d89a

Browse files
Merge pull request #41 from richan-fongdasen/issue-40
Closes #40 - Add Laravel 10 Compatibility and Fix The Github Actions Issue
2 parents a12500c + 7192519 commit 564d89a

File tree

1 file changed

+26
-2
lines changed

1 file changed

+26
-2
lines changed

.github/workflows/main.yml

Lines changed: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ on:
44
pull_request:
55
paths-ignore: ['*.md']
66
push:
7-
branches: [master]
87
paths-ignore: ['*.md']
98

109
jobs:
@@ -32,6 +31,31 @@ jobs:
3231
- name: Run PHPUnit tests and generate code coverage
3332
run: |
3433
composer analyse
35-
phpdbg -qrr vendor/bin/phpunit --coverage-clover=clover.xml
34+
vendor/bin/phpunit
35+
test-coverage:
36+
name: Test (PHP ${{ matrix.php }})
37+
runs-on: ubuntu-latest
38+
strategy:
39+
matrix:
40+
php: [ 8.2 ]
41+
steps:
42+
- name: Checkout repository
43+
uses: actions/checkout@v2
44+
- name: Set up PHP
45+
uses: shivammathur/setup-php@v2
46+
with:
47+
php-version: ${{ matrix.php }}
48+
- name: Cache Composer dependencies
49+
uses: actions/cache@v1
50+
with:
51+
path: ~/.composer/cache/files
52+
key: php-${{ matrix.php }}-composer-${{ hashFiles('**/composer.lock') }}
53+
restore-keys: php-${{ matrix.php }}-composer-
54+
- name: Install composer dependencies
55+
run: composer install --no-interaction --prefer-source
56+
- name: Run PHPUnit tests and generate code coverage
57+
run: |
58+
composer analyse
59+
vendor/bin/phpunit --coverage-clover=clover.xml
3660
- name: Upload code coverage results
3761
run: bash <(curl -s https://codecov.io/bash)

0 commit comments

Comments
 (0)