Skip to content

Commit 2e30e76

Browse files
author
Robert Allport
authored
Add Laravel 11 support (#34)
* Add Laravel 11 support
1 parent e6d15c9 commit 2e30e76

File tree

4 files changed

+34
-47
lines changed

4 files changed

+34
-47
lines changed

.github/workflows/run-tests.yml

Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,20 +10,26 @@ jobs:
1010
fail-fast: false
1111
matrix:
1212
php: [8.3, 8.2, 8.1, 8.0]
13-
laravel: ["^10.0", "^9.0", "^8.12"]
13+
laravel: ["^11.0", "^10.0", "^9.0", "^8.12"]
1414
dependency-version: [prefer-lowest, prefer-stable]
1515
include:
16-
- laravel: "^10.0"
16+
- laravel: ^11.0
17+
testbench: 9.*
18+
- laravel: ^10.0
1719
testbench: 8.*
18-
- laravel: "^9.0"
20+
- laravel: ^9.0
1921
testbench: 7.*
20-
- laravel: "^8.12"
21-
testbench: "^6.23"
22+
- laravel: ^8.12
23+
testbench: ^6.23
2224
exclude:
23-
- laravel: "^10.0"
25+
- laravel: ^10.0
2426
php: 8.0
25-
- laravel: "^8.12"
27+
- laravel: ^8.12
2628
php: 8.3
29+
- laravel: ^11.0
30+
php: 8.1
31+
- laravel: ^11.0
32+
php: 8.0
2733

2834
name: P${{ matrix.php }} - L${{ matrix.laravel }} - ${{ matrix.dependency-version }}
2935

@@ -49,5 +55,8 @@ jobs:
4955
composer require "laravel/framework:${{ matrix.laravel }}" "orchestra/testbench:${{ matrix.testbench }}" "symfony/console:>=4.3.4" "mockery/mockery:^1.3.2" --no-interaction --no-update
5056
composer update --${{ matrix.dependency-version }} --prefer-dist --no-interaction
5157
58+
- name: Display PHP version
59+
run: php -v | grep ^PHP | cut -d' ' -f2
60+
5261
- name: Execute tests
5362
run: vendor/bin/phpunit

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ A simple package allowing for consistent API responses throughout your Laravel a
1313
## Requirements
1414

1515
- PHP `^8.0`
16-
- Laravel `^8.12`, `^9.0` or `^10.0`
16+
- Laravel `^8.12`, `^9.0`, `^10.0` or `^11.0`
1717

1818
### Legacy Support
1919

composer.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,11 @@
1818
],
1919
"require": {
2020
"php": "^8.0",
21-
"illuminate/support": "^8.12|^9.0|^10.0"
21+
"illuminate/support": "^8.12|^9.0|^10.0|^11.0"
2222
},
2323
"require-dev": {
24-
"orchestra/testbench": "^6.23|^7.0|^8.0",
25-
"phpunit/phpunit": "^9.4"
24+
"orchestra/testbench": "^6.23|^7.0|^8.0|^9.0",
25+
"phpunit/phpunit": "^9.4|^10.1"
2626
},
2727
"autoload": {
2828
"psr-4": {

phpunit.xml.dist

Lines changed: 14 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,17 @@
11
<?xml version="1.0" encoding="UTF-8"?>
2-
<phpunit
3-
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4-
xsi:noNamespaceSchemaLocation="vendor/phpunit/phpunit/phpunit.xsd"
5-
backupGlobals="false"
6-
backupStaticAttributes="false"
7-
bootstrap="vendor/autoload.php"
8-
colors="true"
9-
convertErrorsToExceptions="true"
10-
convertNoticesToExceptions="true"
11-
convertWarningsToExceptions="true"
12-
processIsolation="false"
13-
stopOnFailure="false"
14-
executionOrder="random"
15-
failOnWarning="true"
16-
failOnRisky="true"
17-
failOnEmptyTestSuite="true"
18-
beStrictAboutOutputDuringTests="true"
19-
verbose="true"
2+
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
3+
bootstrap="vendor/autoload.php"
4+
colors="true"
5+
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/10.4/phpunit.xsd"
206
>
21-
<testsuites>
22-
<testsuite name="Test Suite">
23-
<directory>tests</directory>
24-
</testsuite>
25-
</testsuites>
26-
<coverage>
27-
<include>
28-
<directory suffix=".php">./src</directory>
29-
</include>
30-
<report>
31-
<html outputDirectory="build/coverage"/>
32-
<text outputFile="build/coverage.txt"/>
33-
<clover outputFile="build/logs/clover.xml"/>
34-
</report>
35-
</coverage>
36-
<logging>
37-
<junit outputFile="build/report.junit.xml"/>
38-
</logging>
7+
<source>
8+
<include>
9+
<directory suffix=".php">src/</directory>
10+
</include>
11+
</source>
12+
<testsuites>
13+
<testsuite name="Test Suite">
14+
<directory>tests</directory>
15+
</testsuite>
16+
</testsuites>
3917
</phpunit>

0 commit comments

Comments
 (0)