Skip to content

Commit fda6610

Browse files
authored
Merge pull request #16 from dicoding-dev/bugfix/fix-error-unit-test
chore: integrate `setup-php` and update workflow for Composer and PHPUnit
2 parents 3e8e907 + cabfc0d commit fda6610

File tree

1 file changed

+11
-8
lines changed

1 file changed

+11
-8
lines changed

.github/workflows/pull-request-check.yml

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -9,20 +9,23 @@ jobs:
99
- name: Checkout repository
1010
uses: actions/checkout@v3
1111

12+
- name: Setup PHP
13+
uses: shivammathur/setup-php@v2
14+
with:
15+
php-version: '8.2'
16+
tools: composer
17+
coverage: none
18+
1219
- name: Cache Composer dependencies
1320
uses: actions/cache@v3
1421
with:
1522
path: /tmp/composer-cache
1623
key: ${{ runner.os }}-${{ hashFiles('composer.lock') }}
1724

1825
- name: Installing dependencies
19-
uses: php-actions/composer@v6
20-
with:
21-
php_version: 8.2
26+
env:
27+
COMPOSER_CACHE_DIR: /tmp/composer-cache
28+
run: composer install --no-interaction --no-progress --prefer-dist
2229

2330
- name: Running unit test
24-
uses: php-actions/phpunit@v3
25-
with:
26-
version: 9.6
27-
php_version: 8.2
28-
configuration: phpunit.xml
31+
run: vendor/bin/phpunit --configuration phpunit.xml

0 commit comments

Comments
 (0)