Skip to content

Commit a664b21

Browse files
committed
chore: drops php 8.1 and php 8.2
1 parent 779afa8 commit a664b21

File tree

5 files changed

+31
-43
lines changed

5 files changed

+31
-43
lines changed

.github/workflows/frameworks.yaml

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
matrix:
1515
os: [ubuntu-latest]
1616
version: ['@stable', '@dev'] # Test current LTS, current release, and future release
17-
php: ['8.1', '8.2', '8.3', '8.4', '8.5']
17+
php: ['8.3', '8.4', '8.5']
1818
composer-version: [v2]
1919
include:
2020
- version: '@stable'
@@ -84,21 +84,16 @@ jobs:
8484
fail-fast: false
8585
matrix:
8686
os: [ubuntu-latest]
87-
version: ['^10.0', '^11.0', '^12.0']
88-
php: ['8.1', '8.2', '8.3']
87+
version: ['^11.0', '^12.0', '^13.0']
88+
php: ['8.3', '8.4', '8.5']
8989
composer-version: [v2]
9090
include:
91-
- version: '^10.0'
92-
phpunit: '^10.0'
9391
- version: '^11.0'
9492
phpunit: '^11.0'
9593
- version: '^12.0'
9694
phpunit: '^11.0'
97-
exclude:
98-
- version: '^11.0'
99-
php: '8.1'
100-
- version: '^12.0'
101-
php: '8.1'
95+
- version: '^13.0'
96+
phpunit: '^12.0'
10297
name: "Laravel:${{ matrix.version }} - PHP${{ matrix.php }} - Composer ${{ matrix.composer-version }}"
10398

10499
steps:

.github/workflows/standalone.yaml

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,16 +13,14 @@ jobs:
1313
fail-fast: false
1414
matrix:
1515
os: [ubuntu-latest, macos-latest, windows-latest]
16-
php: ['8.1', '8.2', '8.3', '8.4']
16+
php: ['8.3', '8.4', '8.5']
1717
dependency-version: [prefer-lowest, prefer-stable]
1818
composer-version: [v2]
1919
exclude:
20-
- dependency-version: prefer-lowest
21-
php: '8.1'
22-
- dependency-version: prefer-lowest
23-
php: '8.2'
2420
- dependency-version: prefer-lowest
2521
php: '8.3'
22+
- dependency-version: prefer-lowest
23+
php: '8.4'
2624
name: ${{ matrix.php }} - ${{ matrix.os }} - Composer ${{ matrix.composer-version }} --${{ matrix.dependency-version }}
2725

2826
steps:

.github/workflows/test.yaml

Lines changed: 7 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -11,35 +11,25 @@ jobs:
1111
strategy:
1212
fail-fast: false
1313
matrix:
14-
php: ['8.1', '8.2', '8.3', '8.4']
14+
php: ['8.3', '8.4', '8.5']
1515
dependency-version: [prefer-lowest, prefer-stable]
1616
composer-version: [ v2 ]
1717
include:
18-
- php: '8.4'
18+
- php: '8.5'
1919
phpunit: '^12.0'
20-
- php: '8.3'
20+
- php: '8.4'
2121
phpunit: '^12.0'
2222
- php: '8.3'
2323
phpunit: '^12.0'
24-
- php: '8.2'
25-
phpunit: '^12.0'
26-
- php: '8.3'
27-
phpunit: '^11.0'
28-
- php: '8.2'
24+
- php: '8.4'
2925
phpunit: '^11.0'
3026
- php: '8.3'
31-
phpunit: '^10.0'
32-
- php: '8.2'
33-
phpunit: '^10.0'
34-
- php: '8.1'
35-
phpunit: '^10.0'
27+
phpunit: '^11.0'
3628
exclude:
37-
- dependency-version: prefer-lowest
38-
php: '8.1'
39-
- dependency-version: prefer-lowest
40-
php: '8.2'
4129
- dependency-version: prefer-lowest
4230
php: '8.3'
31+
- dependency-version: prefer-lowest
32+
php: '8.4'
4333
name: ${{ matrix.php }} - Composer ${{ matrix.composer-version }} --${{ matrix.dependency-version }}
4434

4535
steps:

composer.json

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
}
1818
],
1919
"require": {
20-
"php": "^8.1",
20+
"php": "^8.3",
2121
"ext-iconv": "*",
2222
"ext-json": "*",
2323
"ext-mbstring": "*",
@@ -29,22 +29,22 @@
2929
"php-parallel-lint/php-parallel-lint": "^1.4.0",
3030
"psr/container": "^2.0.2",
3131
"psr/simple-cache": "^2.0|^3.0",
32-
"sebastian/diff": "^5.1.1|^6.0.2|^7.0.0",
32+
"sebastian/diff": "^6.0.2|^7.0.0",
3333
"slevomat/coding-standard": "^8.22.1",
3434
"squizlabs/php_codesniffer": "^3.13.5",
35-
"symfony/cache": "^6.4.20|^7.4.5|^8.0.5",
36-
"symfony/console": "^6.4.20|^7.4.4|^8.0",
37-
"symfony/finder": "^6.4.17|^7.4.5|^8.0",
38-
"symfony/http-client": "^6.4.19|^7.4.5|^8.0.5",
39-
"symfony/process": "^6.4.20|^7.4.5|^8.0"
35+
"symfony/cache": "^7.4.5|^8.0.5",
36+
"symfony/console": "^7.4.4|^8.0.4",
37+
"symfony/finder": "^7.4.5|^8.0.5",
38+
"symfony/http-client": "^7.4.5|^8.0.5",
39+
"symfony/process": "^7.4.5|^8.0.5"
4040
},
4141
"require-dev": {
42-
"illuminate/console": "^10.48.28|^11.44.2|^12.52",
43-
"illuminate/support": "^10.48.28|^11.44.2|^12.52",
42+
"illuminate/console": "^11.44.2|^12.52|^13.0",
43+
"illuminate/support": "^11.44.2|^12.52|^13.0",
4444
"mockery/mockery": "^1.6.12",
4545
"phpstan/phpstan": "^2.1.39",
46-
"phpunit/phpunit": "^10.5.45|^11.5.55",
47-
"symfony/var-dumper": "^6.4.18|^7.4.4|^8.0.4"
46+
"phpunit/phpunit": "^11.5.55|^12.5.14",
47+
"symfony/var-dumper": "^7.4.4|^8.0.4"
4848
},
4949
"suggest": {
5050
"ext-simplexml": "It is needed for the checkstyle formatter"

tests/TestCase.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
use PHP_CodeSniffer\Config;
1515
use PHP_CodeSniffer\Files\LocalFile;
1616
use PHP_CodeSniffer\Ruleset;
17+
use PHP_CodeSniffer\Util\MessageCollector;
1718
use PHPUnit\Framework\TestCase as BaseTestCase;
1819
use ReflectionClass;
1920
use ReflectionException;
@@ -143,6 +144,10 @@ class_basename($sniffClassName)
143144
/** @var Ruleset $ruleset */
144145
$ruleset = (new ReflectionClass(Ruleset::class))
145146
->newInstanceWithoutConstructor();
147+
148+
$msgCacheProperty = (new ReflectionClass(Ruleset::class))->getProperty('msgCache');
149+
$msgCacheProperty->setValue($ruleset, new MessageCollector());
150+
146151
$ruleset->ruleset = [
147152
"PhpInsights.Sniffs.{$ruleName}" => [
148153
'properties' => $properties,

0 commit comments

Comments
 (0)