Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Laravel 11.x Compatibility #213

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
81 changes: 39 additions & 42 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,50 +17,47 @@ jobs:
strategy:
fail-fast: false
matrix:
php:
- '8.1'
- '8.2'
laravel:
- 9.*
- 10.*
prefer:
- 'prefer-lowest'
- 'prefer-stable'
php: ['8.2', '8.3']
laravel: ['10.*', '11.*']
prefer: [prefer-lowest, prefer-stable]
include:
- laravel: 9.*
testbench: 7.*
- laravel: 10.*
testbench: 8.*
- laravel: '10.*'
testbench: '8.*'
- laravel: '11.*'
testbench: '9.*'
exclude:
- laravel: '11.*'
php: '8.1'

name: PHP ${{ matrix.php }} - Laravel ${{ matrix.laravel }} --${{ matrix.prefer }}

steps:
- uses: actions/checkout@v3

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv
coverage: pcov

- uses: actions/cache@v3.0.11
name: Cache dependencies
with:
path: ~/.composer/cache/files
key: composer-php-${{ matrix.php }}-${{ matrix.laravel }}-${{ matrix.prefer }}-${{ hashFiles('composer.json') }}

- name: Install dependencies
run: |
composer require "laravel/framework:${{ matrix.laravel }}" "orchestra/testbench:${{ matrix.testbench }}" --no-interaction --no-update
composer update --${{ matrix.prefer }} --prefer-dist --no-interaction --no-suggest

- name: Run tests
run: |
CACHE_DRIVER=array vendor/bin/phpunit --coverage-text --coverage-clover=coverage_array.xml
CACHE_DRIVER=file vendor/bin/phpunit --coverage-text --coverage-clover=coverage_file.xml

- uses: codecov/codecov-action@v3.1.1
with:
fail_ci_if_error: false
file: '*.xml'
- uses: actions/checkout@v3

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv
coverage: pcov

- uses: actions/cache@v3.0.11
name: Cache dependencies
with:
path: ~/.composer/cache/files
key: composer-php-${{ matrix.php }}-${{ matrix.laravel }}-${{ matrix.prefer }}-${{ hashFiles('composer.json') }}

- name: Install dependencies
run: |
composer require "laravel/framework:${{ matrix.laravel }}" "orchestra/testbench:${{ matrix.testbench }}" --no-interaction --no-update
composer update --${{ matrix.prefer }} --prefer-dist --no-interaction --no-suggest

- name: Run tests
run: |
CACHE_DRIVER=array vendor/bin/phpunit --coverage-text --coverage-clover=coverage_array.xml
CACHE_DRIVER=file vendor/bin/phpunit --coverage-text --coverage-clover=coverage_file.xml

- uses: codecov/codecov-action@v3.1.1
with:
fail_ci_if_error: false
file: '*.xml'
8 changes: 4 additions & 4 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@
}
],
"require": {
"illuminate/database": "^9.35|^10.5",
"illuminate/support": "^9.35|^10.5"
"illuminate/database": "^10.5|^11.0",
"illuminate/support": "^10.5|^11.0"
},
"autoload": {
"psr-4": {
Expand All @@ -41,8 +41,8 @@
"laravel/legacy-factories": "^1.3",
"livewire/livewire": "dev-master",
"mockery/mockery": "^1.5",
"orchestra/testbench": "^7.23|^8.1.1",
"phpunit/phpunit": "^9.5.25"
"orchestra/testbench": "^8.1.1|^9.0",
"phpunit/phpunit": "^9.5.25|^10.5"
},
"config": {
"sort-packages": true
Expand Down
Loading