Skip to content

Commit c8f71f2

Browse files
committed
Laravel 12 support
1 parent 9206866 commit c8f71f2

File tree

6 files changed

+39
-43
lines changed

6 files changed

+39
-43
lines changed

.github/workflows/analyse.yml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,10 @@ jobs:
99
fail-fast: true
1010
matrix:
1111
os: [ubuntu-latest]
12-
php: [8.3]
13-
laravel: [10.*, 11.*]
12+
php: [8.3, 8.4]
13+
laravel: [11.*]
1414
stability: [prefer-stable]
1515
include:
16-
- laravel: 10.*
17-
testbench: 8.*
1816
- laravel: 11.*
1917
testbench: 9.*
2018

.github/workflows/coverage.yml

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,10 @@ jobs:
99
fail-fast: true
1010
matrix:
1111
os: [ubuntu-latest]
12-
php: [8.3]
13-
laravel: [10.*, 11.*]
14-
stability: [prefer-stable]
12+
php: [8.4]
13+
laravel: [11.*]
14+
stability: [prefer-lowest, prefer-stable]
1515
include:
16-
- laravel: 10.*
17-
testbench: 8.*
1816
- laravel: 11.*
1917
testbench: 9.*
2018

@@ -33,8 +31,7 @@ jobs:
3331

3432
- name: Install dependencies
3533
run: |
36-
composer config allow-plugins.pestphp/pest-plugin true
37-
composer require "laravel/framework:${{ matrix.laravel }}" "orchestra/testbench:${{ matrix.testbench }}" pestphp/pest --no-interaction --no-update
34+
composer require "laravel/framework:${{ matrix.laravel }}" "orchestra/testbench:${{ matrix.testbench }}" --no-interaction --no-update
3835
composer update --${{ matrix.stability }} --prefer-dist --no-interaction
3936
- name: Execute tests
40-
run: XDEBUG_MODE=coverage php vendor/bin/pest --coverage --min=100
37+
run: composer coverage

.github/workflows/style.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
- name: Setup PHP
1717
uses: shivammathur/setup-php@v2
1818
with:
19-
php-version: 8.3
19+
php-version: 8.4
2020
extensions: dom, curl, libxml, mbstring, zip, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv, imagick, fileinfo
2121
coverage: none
2222

.github/workflows/tests.yml

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,17 +9,12 @@ jobs:
99
fail-fast: true
1010
matrix:
1111
os: [ubuntu-latest]
12-
php: [8.1, 8.2, 8.3]
13-
laravel: [10.*, 11.*]
12+
php: [8.2, 8.3]
13+
laravel: [11.*]
1414
stability: [prefer-lowest, prefer-stable]
1515
include:
16-
- laravel: 10.*
17-
testbench: 8.*
1816
- laravel: 11.*
1917
testbench: 9.*
20-
exclude:
21-
- laravel: 11.*
22-
php: 8.1
2318

2419
name: P${{ matrix.php }} - L${{ matrix.laravel }} - ${{ matrix.stability }} - ${{ matrix.os }}
2520

composer.json

Lines changed: 17 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,16 @@
66
"require": {
77
"php": "^8.1",
88
"guzzlehttp/guzzle": "^7.5",
9-
"laravel/framework": "^10.0|^11.0",
9+
"laravel/framework": "^11.0|^12.0",
1010
"league/oauth1-client": "^1.10"
1111
},
1212
"require-dev": {
13-
"laravel/pint": "^1.7",
14-
"larastan/larastan": "^2.5",
15-
"phpstan/phpstan-mockery": "^1.1",
16-
"phpunit/phpunit": "^10.1",
17-
"orchestra/testbench": "^8.0|^9.0"
13+
"larastan/larastan": "^3.0",
14+
"laravel/pint": "^1.20",
15+
"orchestra/testbench": "^9.0",
16+
"pestphp/pest": "^3.7",
17+
"phpstan/phpstan-mockery": "^2.0",
18+
"phpunit/phpunit": "^11.5"
1819
},
1920
"authors": [
2021
{
@@ -40,17 +41,22 @@
4041
},
4142
"scripts": {
4243
"test": "phpunit",
43-
"analyse": "phpstan",
44+
"analyse": "phpstan --memory-limit=256M",
4445
"style": "pint --test",
4546
"quality": [
46-
"@test",
47+
"@style",
4748
"@analyse",
48-
"@style"
49+
"@test",
50+
"@coverage"
4951
],
50-
"fix-style": "pint"
52+
"fix-style": "pint",
53+
"coverage": "XDEBUG_MODE=coverage php vendor/bin/pest --coverage --min=100"
5154
},
5255
"config": {
53-
"sort-packages": true
56+
"sort-packages": true,
57+
"allow-plugins": {
58+
"pestphp/pest-plugin": true
59+
}
5460
},
5561
"extra": {
5662
"laravel": {

tests/Query/SearchCriteriaTest.php

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ public function test_it_can_add_multiple_wheres(): void
5151
], $searchCriteria);
5252
}
5353

54-
public function test_it_can_add_orWhere(): void
54+
public function test_it_can_add_or_where(): void
5555
{
5656
$searchCriteria = SearchCriteria::make()
5757
->where('sku', '=', '::some-sku::')
@@ -68,7 +68,7 @@ public function test_it_can_add_orWhere(): void
6868
], $searchCriteria);
6969
}
7070

71-
public function test_it_can_add_multiple_orWhere(): void
71+
public function test_it_can_add_multiple_or_where(): void
7272
{
7373
$searchCriteria = SearchCriteria::make()
7474
->where('sku', '=', '::some-sku::')
@@ -97,7 +97,7 @@ public function test_it_can_add_multiple_orWhere(): void
9797
], $searchCriteria);
9898
}
9999

100-
public function test_it_can_add_whereIn(): void
100+
public function test_it_can_add_where_in(): void
101101
{
102102
$searchCriteria = SearchCriteria::make()
103103
->whereIn('sku', ['::sku_1::', '::sku_2::', '::sku_3::'])
@@ -110,7 +110,7 @@ public function test_it_can_add_whereIn(): void
110110
], $searchCriteria);
111111
}
112112

113-
public function test_it_can_add_orWhereIn(): void
113+
public function test_it_can_add_or_where_in(): void
114114
{
115115
$searchCriteria = SearchCriteria::make()
116116
->whereIn('sku', ['::sku_1::', '::sku_2::', '::sku_3::'])
@@ -128,7 +128,7 @@ public function test_it_can_add_orWhereIn(): void
128128
], $searchCriteria);
129129
}
130130

131-
public function test_it_can_add_whereNotIn(): void
131+
public function test_it_can_add_where_not_in(): void
132132
{
133133
$searchCriteria = SearchCriteria::make()
134134
->whereNotIn('sku', ['::sku_1::', '::sku_2::', '::sku_3::'])
@@ -141,7 +141,7 @@ public function test_it_can_add_whereNotIn(): void
141141
], $searchCriteria);
142142
}
143143

144-
public function test_it_can_add_orWhereNotIn(): void
144+
public function test_it_can_add_or_where_not_in(): void
145145
{
146146
$searchCriteria = SearchCriteria::make()
147147
->whereNotIn('sku', ['::sku_1::', '::sku_2::', '::sku_3::'])
@@ -199,7 +199,7 @@ public function test_it_can_dd(): void
199199
$searchCriteria->dd();
200200
}
201201

202-
public function test_it_can_add_whereNull(): void
202+
public function test_it_can_add_where_null(): void
203203
{
204204
$searchCriteria = SearchCriteria::make()
205205
->where('sku', '=', '::sku::')
@@ -215,7 +215,7 @@ public function test_it_can_add_whereNull(): void
215215
], $searchCriteria);
216216
}
217217

218-
public function test_it_can_add_orWhereNull(): void
218+
public function test_it_can_add_or_where_null(): void
219219
{
220220
$searchCriteria = SearchCriteria::make()
221221
->whereNull('::some_field::')
@@ -230,7 +230,7 @@ public function test_it_can_add_orWhereNull(): void
230230
], $searchCriteria);
231231
}
232232

233-
public function test_it_can_add_whereNotNull(): void
233+
public function test_it_can_add_where_not_null(): void
234234
{
235235
$searchCriteria = SearchCriteria::make()
236236
->where('sku', '=', '::sku::')
@@ -246,7 +246,7 @@ public function test_it_can_add_whereNotNull(): void
246246
], $searchCriteria);
247247
}
248248

249-
public function test_it_can_add_orWhereNotNull(): void
249+
public function test_it_can_add_or_where_not_null(): void
250250
{
251251
$searchCriteria = SearchCriteria::make()
252252
->whereNotNull('::some_field::')
@@ -261,7 +261,7 @@ public function test_it_can_add_orWhereNotNull(): void
261261
], $searchCriteria);
262262
}
263263

264-
public function test_it_can_orderBy(): void
264+
public function test_it_can_order_by(): void
265265
{
266266
$searchCriteria = SearchCriteria::make()
267267
->orderBy('sku')
@@ -273,7 +273,7 @@ public function test_it_can_orderBy(): void
273273
], $searchCriteria);
274274
}
275275

276-
public function test_it_can_orderByDesc(): void
276+
public function test_it_can_order_by_desc(): void
277277
{
278278
$searchCriteria = SearchCriteria::make()
279279
->orderByDesc('sku')

0 commit comments

Comments
 (0)