Skip to content

Commit 8ea5b00

Browse files
Laravel 12.x Compatibility (#97)
* Bump dependencies for Laravel 12 * Update GitHub Actions for Laravel 12 * Formatting --------- Co-authored-by: Randall Wilk <[email protected]>
1 parent d61b087 commit 8ea5b00

File tree

2 files changed

+73
-69
lines changed

2 files changed

+73
-69
lines changed

.github/workflows/pest.yml

Lines changed: 68 additions & 64 deletions
Original file line numberDiff line numberDiff line change
@@ -1,77 +1,81 @@
11
name: Tests
22

33
on:
4-
push:
5-
paths:
6-
- '**.php'
7-
- phpunit.xml.dist
8-
- .github/workflows/pest.yml
9-
- composer.json
10-
pull_request:
11-
branches:
12-
- main
4+
push:
5+
paths:
6+
- '**.php'
7+
- phpunit.xml.dist
8+
- .github/workflows/pest.yml
9+
- composer.json
10+
pull_request:
11+
branches:
12+
- main
1313

1414
jobs:
15-
test:
16-
runs-on: ubuntu-latest
15+
test:
16+
runs-on: ubuntu-latest
1717

18-
strategy:
19-
fail-fast: true
20-
matrix:
21-
php: [8.3, 8.2, 8.1]
22-
laravel: ['8.*', '9.*', '10.*', '11.*']
23-
stability: [prefer-lowest, prefer-stable]
24-
include:
25-
- laravel: 10.*
26-
testbench: 8.*
27-
- laravel: 9.*
28-
testbench: 7.*
29-
- laravel: 8.*
30-
testbench: ^6.23
31-
- laravel: 11.*
32-
testbench: 9.*
33-
exclude:
34-
- laravel: 9.*
35-
php: 8.2
36-
stability: prefer-lowest
37-
- laravel: 9.*
38-
php: 8.3
39-
- laravel: 8.*
40-
php: 8.2
41-
stability: prefer-lowest
42-
- laravel: 8.*
43-
php: 8.3
44-
- laravel: 11.*
45-
php: 8.1
18+
strategy:
19+
fail-fast: true
20+
matrix:
21+
php: [8.3, 8.2, 8.1]
22+
laravel: [12.*, 11.*, 10.*, 9.*, 8.*]
23+
stability: [prefer-lowest, prefer-stable]
24+
include:
25+
- laravel: 10.*
26+
testbench: 8.*
27+
- laravel: 9.*
28+
testbench: 7.*
29+
- laravel: 8.*
30+
testbench: ^6.23
31+
- laravel: 11.*
32+
testbench: 9.*
33+
- laravel: 12.*
34+
testbench: 10.*
35+
exclude:
36+
- laravel: 9.*
37+
php: 8.2
38+
stability: prefer-lowest
39+
- laravel: 9.*
40+
php: 8.3
41+
- laravel: 8.*
42+
php: 8.2
43+
stability: prefer-lowest
44+
- laravel: 8.*
45+
php: 8.3
46+
- laravel: 11.*
47+
php: 8.1
48+
- laravel: 12.*
49+
php: 8.1
4650

47-
name: P${{ matrix.php }} - L${{ matrix.laravel }} - ${{ matrix.stability }}
51+
name: P${{ matrix.php }} - L${{ matrix.laravel }} - ${{ matrix.stability }}
4852

49-
steps:
50-
- name: Checkout code
51-
uses: actions/checkout@v3
53+
steps:
54+
- name: Checkout code
55+
uses: actions/checkout@v3
5256

53-
- name: Setup PHP
54-
uses: shivammathur/setup-php@v2
55-
with:
56-
php-version: ${{ matrix.php }}
57-
extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv, imagick, fileinfo
58-
coverage: none
57+
- name: Setup PHP
58+
uses: shivammathur/setup-php@v2
59+
with:
60+
php-version: ${{ matrix.php }}
61+
extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv, imagick, fileinfo
62+
coverage: none
5963

60-
- name: Setup problem matchers
61-
run: |
62-
echo "::add-matcher::${{ runner.tool_cache }}/php.json"
63-
echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json"
64+
- name: Setup problem matchers
65+
run: |
66+
echo "::add-matcher::${{ runner.tool_cache }}/php.json"
67+
echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json"
6468
65-
- name: Install dependencies
66-
run: |
67-
composer require "laravel/framework:${{ matrix.laravel }}" "orchestra/testbench:${{ matrix.testbench }}" --no-interaction --no-update --ignore-platform-reqs
68-
composer update --${{ matrix.stability }} --prefer-dist --no-interaction --ignore-platform-reqs
69+
- name: Install dependencies
70+
run: |
71+
composer require "laravel/framework:${{ matrix.laravel }}" "orchestra/testbench:${{ matrix.testbench }}" --no-interaction --no-update --ignore-platform-reqs
72+
composer update --${{ matrix.stability }} --prefer-dist --no-interaction --ignore-platform-reqs
6973
70-
- name: List Installed Dependencies
71-
run: composer show -D
74+
- name: List Installed Dependencies
75+
run: composer show -D
7276

73-
- name: Execute tests
74-
run: vendor/bin/pest
75-
env:
76-
PRINT_NODE_API_KEY: ${{ secrets.PRINT_NODE_API_KEY }}
77-
PRINT_NODE_ID: ${{ secrets.PRINT_NODE_ID }}
77+
- name: Execute tests
78+
run: vendor/bin/pest
79+
env:
80+
PRINT_NODE_API_KEY: ${{ secrets.PRINT_NODE_API_KEY }}
81+
PRINT_NODE_ID: ${{ secrets.PRINT_NODE_ID }}

composer.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,19 +24,19 @@
2424
"require": {
2525
"php": "^8.0|^8.1|^8.2|^8.3",
2626
"guzzlehttp/guzzle": "^7.5",
27-
"illuminate/support": "^8.0|^9.0|^10.0|^11.0",
27+
"illuminate/support": "^8.0|^9.0|^10.0|^11.0|^12.0",
2828
"mike42/escpos-php": "^4.0",
2929
"spatie/laravel-package-tools": "^1.2|^1.13"
3030
},
3131
"require-dev": {
3232
"laravel/pint": "^1.5",
3333
"mockery/mockery": ">=1.4",
34-
"orchestra/testbench": "^6.0|^7.0|^8.0|^9.0",
35-
"pestphp/pest": "^1.20|^2.34",
36-
"pestphp/pest-plugin-laravel": "^1.0|^2.2",
34+
"orchestra/testbench": "^6.0|^7.0|^8.0|^9.0|^10.0",
35+
"pestphp/pest": "^1.20|^2.34|^3.7",
36+
"pestphp/pest-plugin-laravel": "^1.0|^2.2|^3.1",
3737
"php-http/socket-client": "^2.1",
3838
"php-http/message-factory": "^1.1",
39-
"psr/http-message": "1.*",
39+
"psr/http-message": "1.*|^2.0",
4040
"psr/http-client": "^1.0",
4141
"smalot/cups-ipp": "^0.5.0",
4242
"spatie/laravel-ray": "^1.0|^1.29"

0 commit comments

Comments
 (0)