Skip to content

Commit

Permalink
Update laravel.yml
Browse files Browse the repository at this point in the history
Updating Laravel Workflow:
- Updating PHP version
- Updating setup-php actions
- Updating checkout actions
- Using migration
- using artisan test for a better management of executing tests (phpunit/pestphp)
  • Loading branch information
roberto-butti committed Apr 25, 2024
1 parent ac9c407 commit 2f4319d
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions ci/laravel.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: shivammathur/setup-php@15c43e89cdef867065b0213be354c2841860869e
- uses: shivammathur/setup-php@v2
with:
php-version: '8.0'
- uses: actions/checkout@v3
php-version: '8.3'
- uses: actions/checkout@v4
- name: Copy .env
run: php -r "file_exists('.env') || copy('.env.example', '.env');"
- name: Install Dependencies
Expand All @@ -24,12 +24,14 @@ jobs:
run: php artisan key:generate
- name: Directory Permissions
run: chmod -R 777 storage bootstrap/cache
- name: Create Database
- name: Execute migrations
env:
DB_CONNECTION: sqlite
run: |
mkdir -p database
touch database/database.sqlite
- name: Execute tests (Unit and Feature tests) via PHPUnit/Pest
php artisan migrate
- name: Execute tests (Unit and Feature tests) via PHPUnit
env:
DB_CONNECTION: sqlite
DB_DATABASE: database/database.sqlite
run: php artisan test

0 comments on commit 2f4319d

Please sign in to comment.