Add Laravel app setup in CI

This commit is contained in:
Christopher C. Wells 2021-03-28 15:07:13 -07:00 committed by Christopher Charbonneau Wells
parent 5b73358912
commit 872528b47f
1 changed files with 6 additions and 8 deletions

View File

@ -7,18 +7,16 @@ jobs:
- uses: shivammathur/setup-php@v2
with:
php-version: '8.0'
extensions: exif
coverage: xdebug
- uses: actions/checkout@v2
- name: Install dependencies
run: composer install --no-progress --no-interaction
- name: Generate app key
run: |
php -r "file_exists('.env') || copy('.env.example', '.env');"
php artisan key:generate
- name: Run tests
uses: php-actions/phpunit@v2
with:
php_extensions: xdebug
configuration: phpunit.xml
args: --coverage-clover build/logs/clover.xml
env:
XDEBUG_MODE: coverage
run: vendor/bin/phpunit --coverage-clover build/logs/clover.xml
- name: Upload coverage results to Coveralls
env:
COVERALLS_REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }}