Update to Laravel 9 #95
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: CI | |
on: | |
push: | |
branches: | |
- '9.x' | |
pull_request: | |
branches: | |
- '9.x' | |
env: | |
APP_ENV: test | |
jobs: | |
laravel: | |
name: Laravel 9 (PHP ${{ matrix.php-versions }}) | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: true | |
matrix: | |
php-versions: ['8.0', '8.1', '8.2'] | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Setup PHP | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: ${{ matrix.php-versions }} | |
tools: composer:v2 | |
extensions: ctype, iconv, intl, json, mbstring, pdo, pdo_sqlite, fileinfo | |
env: | |
update: true | |
- name: Get composer cache directory | |
id: composer-cache | |
run: echo "::set-output name=dir::$(composer config cache-files-dir)" | |
- name: Cache composer dependencies | |
uses: actions/[email protected] | |
with: | |
path: ${{ steps.composer-cache.outputs.dir }} | |
key: ${{ runner.os }}-${{ matrix.php-versions }}-composer-${{ hashFiles('composer.json') }} | |
restore-keys: ${{ runner.os }}-${{ matrix.php-versions }}-composer- | |
- name: Install Composer dependencies | |
run: composer update --no-progress | |
- name: Set up Laravel environment | |
run: | | |
cp .env.testing .env | |
php artisan config:cache | |
touch database/database.sqlite | |
php artisan migrate --seed --env=testing --force | |
- name: Run functional tests | |
run: vendor/bin/codecept run Functional |