Add Player Badges #1302
Workflow file for this run
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: Laravel | |
on: | |
pull_request: | |
branches: | |
- '**' | |
push: | |
branches-ignore: | |
- '**' | |
tags-ignore: | |
- '**' | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
laravel-tests: | |
runs-on: ubuntu-latest | |
services: | |
maria: | |
image: mariadb:10.6 | |
env: | |
MYSQL_ALLOW_EMPTY_PASSWORD: yes | |
MYSQL_DATABASE: leafapp_test | |
ports: | |
- 3306 | |
options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Copy .env | |
run: php -r "file_exists('.env') || copy('.env.example', '.env');" | |
- name: Setup PHP with tools | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: '8.2' | |
coverage: xdebug | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: '14' | |
cache: 'yarn' | |
- name: Install Composer Dependencies | |
run: composer install -q --no-ansi --no-interaction --no-scripts --no-suggest --no-progress --prefer-dist | |
- name: Install Yarn Dependencies | |
run: yarn install | |
- name: Generate key | |
run: php artisan key:generate | |
- name: Directory Permissions | |
run: chmod -R 777 storage bootstrap/cache | |
- name: Asset Packaging | |
run: yarn run build | |
- name: Asset Storage Link | |
run: php artisan storage:link | |
- name: PHPCS | |
run: vendor/bin/pint --test | |
- name: Execute tests (With Coverage) via PHPUnit | |
env: | |
DB_PORT: ${{ job.services.maria.ports[3306] }} | |
run: php artisan test --without-tty --coverage --min=100 --coverage-html=output | |
- name: PHPStan | |
run: vendor/bin/phpstan analyse --xdebug | |
- uses: actions/upload-artifact@v3 | |
if: failure() | |
with: | |
name: coverage-html | |
path: output | |
if-no-files-found: ignore |