Skip to content

Commit

Permalink
Support Laravel 11
Browse files Browse the repository at this point in the history
  • Loading branch information
sethsandaru committed Mar 13, 2024
1 parent ee3fdef commit ac4c4f3
Show file tree
Hide file tree
Showing 4 changed files with 62 additions and 4 deletions.
27 changes: 25 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ on:
- 'main'

jobs:
build:
build_php82:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
Expand All @@ -19,7 +19,7 @@ jobs:
- name: Setup PHP with coverage driver
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.version }}
php-version: 8.2
coverage: pcov

- name: Bootstrap project
Expand All @@ -39,3 +39,26 @@ jobs:
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: ./coverage.xml

build_php83:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
if: success()

- name: Setup PHP with coverage driver
uses: shivammathur/setup-php@v2
with:
php-version: 8.3
coverage: pcov

- name: Bootstrap project
if: success()
run: |
php -v
composer install --no-interaction
- name: PHPUnit tests with coverage
if: success() && github.event.pull_request.draft == false
run: |
composer test
35 changes: 35 additions & 0 deletions .github/workflows/try-installation.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Try Install Package (Laravel 10 & 11)

env:
LOCAL_ENV: ${{ secrets.LOCAL_ENV }}

on:
push:
branches:
- 'main'

jobs:
build:
strategy:
fail-fast: false
matrix:
version: [ '^10.0', '^11.0' ]
runs-on: ubuntu-latest
steps:
- name: Setup PHP with coverage driver
uses: shivammathur/setup-php@v2
with:
php-version: 8.2
coverage: pcov

- name: Setup and install package on Laravel
if: success()
run: |
sudo service mysql start
mysql -uroot -proot -e "CREATE DATABASE priority_queue;"
composer create-project laravel/laravel:${{ matrix.version }} laravel
cd laravel
composer require shipsaas/laravel-priority-queue
php artisan vendor:publish --tag=priority-queue-migrations
echo "$LOCAL_ENV" > .env
php artisan migrate
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ A simple yet super effective method to skyrocketing your API responding times
> Laravel Resource Reducer is heavily inspired from GraphQL approach. ❤️
## Supports
- Laravel 10+
- Laravel 10 & 11
- PHP 8.2+

### Compatibility
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
],
"license": "MIT",
"require": {
"php": "^8.2",
"php": ">=8.2",
"laravel/framework": "^10|dev-master"
},
"require-dev": {
Expand Down

0 comments on commit ac4c4f3

Please sign in to comment.