Skip to content

Commit c35b0ac

Browse files
committed
feat: laravel 10 support
1 parent ac40af2 commit c35b0ac

File tree

8 files changed

+22
-22
lines changed

8 files changed

+22
-22
lines changed

composer.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,14 @@
1111
"type": "library",
1212
"require": {
1313
"php": "^8.0",
14-
"illuminate/collections": "^8.0|^9.0",
15-
"illuminate/http": "^8.0|^9.0",
16-
"illuminate/support": "^8.0|^9.0"
14+
"illuminate/collections": "^8.0|^9.0|^10.0",
15+
"illuminate/http": "^8.0|^9.0|^10.0",
16+
"illuminate/support": "^8.0|^9.0|^10.0"
1717
},
1818
"require-dev": {
19-
"phpunit/phpunit": "^9.5.10",
20-
"orchestra/testbench": "^7.0",
21-
"phpstan/phpstan": "1.6.x-dev"
19+
"phpunit/phpunit": "^9.5|^10.0",
20+
"orchestra/testbench": "^7.0|^8.0",
21+
"phpstan/phpstan": "^1.9.18"
2222
},
2323
"license": "MIT",
2424
"autoload": {

tests/Unit/Descriptors/DescriptorsTraitTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
class DescriptorsTraitTest extends TestCase
2424
{
25-
public function methods()
25+
public static function methods()
2626
{
2727
return [
2828
'bool' => [ValueBool::class, 'bool'],

tests/Unit/Descriptors/RelationTest.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515

1616
class RelationTest extends TestCase
1717
{
18-
public function resourceProvider(): array
18+
public static function resourceProvider(): array
1919
{
2020
return [
2121
[[]],
@@ -84,7 +84,7 @@ public function testLinks($model)
8484
$this->assertEquals(['test'], Reflect::get($relation, 'links')());
8585
}
8686

87-
public function dataWhenLoaded()
87+
public static function dataWhenLoaded()
8888
{
8989
return [
9090
['attr', null, 'attr'],
@@ -108,7 +108,7 @@ public function testWhenLoaded($expectedAttr, $relation, $invokedAttr)
108108
$this->assertFalse($check);
109109
}
110110

111-
public function dataWhenPivotLoaded()
111+
public static function dataWhenPivotLoaded()
112112
{
113113
return [
114114
['attr', null, 'attr'],

tests/Unit/Descriptors/ValueTest.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
class ValueTest extends TestCase
2424
{
25-
public function models(): array
25+
public static function models(): array
2626
{
2727
return [
2828
'arrayable' => [collect()],
@@ -33,7 +33,7 @@ public function models(): array
3333
];
3434
}
3535

36-
public function values()
36+
public static function values()
3737
{
3838
date_default_timezone_set('Europe/London');
3939

@@ -70,12 +70,12 @@ public function values()
7070
];
7171
}
7272

73-
public function modelsValues()
73+
public static function modelsValues()
7474
{
7575
$set = [];
7676

77-
foreach ($this->values() as $v => $value) {
78-
foreach ($this->models() as $m => $model) {
77+
foreach (self::values() as $v => $value) {
78+
foreach (self::models() as $m => $model) {
7979
$set["$v.$m"] = [...$model, ...$value];
8080
}
8181
}

tests/Unit/Resources/Concerns/ConditionallyLoadsAttributesTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717

1818
class ConditionallyLoadsAttributesTest extends TestCase
1919
{
20-
public function data()
20+
public static function data()
2121
{
2222
return [
2323
[false, 'test', []],

tests/Unit/Support/ArrTest.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
class ArrTest extends TestCase
99
{
10-
public function mergeProvider()
10+
public static function mergeProvider()
1111
{
1212
return [
1313
// [expected, base, with]
@@ -68,7 +68,7 @@ public function testMerge($expected, $base, $with)
6868
$this->assertEquals($expected, Arr::merge($base, $with));
6969
}
7070

71-
public function washProvider()
71+
public static function washProvider()
7272
{
7373
return [
7474
// [expected, with]
@@ -96,7 +96,7 @@ public function testWash($expected, $base)
9696
$this->assertEquals($expected, Arr::wash($base));
9797
}
9898

99-
public function toArrayProvider()
99+
public static function toArrayProvider()
100100
{
101101
return [
102102
// [expected, with]

tests/Unit/Support/FieldsTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
class FieldsTest extends TestCase
1010
{
11-
public function fieldsGetProvider()
11+
public static function fieldsGetProvider()
1212
{
1313
return [
1414
[[], 'foo', null],

tests/Unit/Support/WithTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
class WithTest extends TestCase
99
{
10-
public function mergeProvider()
10+
public static function mergeProvider()
1111
{
1212
return [
1313
// [expected, base, with]
@@ -68,7 +68,7 @@ public function testMerge($expected, $base, $with)
6868
$this->assertEquals($expected, With::merge($base, $with));
6969
}
7070

71-
public function washProvider()
71+
public static function washProvider()
7272
{
7373
return [
7474
// [expected, with]

0 commit comments

Comments
 (0)