Skip to content

Commit 602418b

Browse files
committed
Merge pull request #292 from lcobucci/require-php81
Require PHP 8.1
2 parents 0f99a20 + 0c9fc22 commit 602418b

17 files changed

+1816
-869
lines changed

.github/workflows/coding-standards.yml

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
dependencies:
1616
- "locked"
1717
php-version:
18-
- "8.0"
18+
- "8.1"
1919
operating-system:
2020
- "ubuntu-latest"
2121

@@ -31,14 +31,16 @@ jobs:
3131
ini-values: memory_limit=-1
3232
tools: composer:v2, cs2pr
3333

34+
- name: Get composer cache directory
35+
id: composer-cache
36+
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
37+
3438
- name: "Cache dependencies"
35-
uses: "actions/[email protected].2"
39+
uses: "actions/[email protected].4"
3640
with:
37-
path: |
38-
~/.composer/cache
39-
vendor
40-
key: "php-${{ matrix.php-version }}-${{ matrix.dependencies }}"
41-
restore-keys: "php-${{ matrix.php-version }}-${{ matrix.dependencies }}"
41+
path: ${{ steps.composer-cache.outputs.dir }}
42+
key: "php-${{ matrix.php-version }}-composer-${{ matrix.dependencies }}-${{ hashFiles('**/composer.lock') }}"
43+
restore-keys: "php-${{ matrix.php-version }}-composer-${{ matrix.dependencies }}-"
4244

4345
- name: "Install lowest dependencies"
4446
if: ${{ matrix.dependencies == 'lowest' }}

.github/workflows/mutation-tests.yml

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
dependencies:
1616
- "locked"
1717
php-version:
18-
- "8.0"
18+
- "8.1"
1919
operating-system:
2020
- "ubuntu-latest"
2121

@@ -31,14 +31,16 @@ jobs:
3131
ini-values: memory_limit=-1
3232
tools: composer:v2, cs2pr
3333

34+
- name: Get composer cache directory
35+
id: composer-cache
36+
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
37+
3438
- name: "Cache dependencies"
35-
uses: "actions/[email protected].2"
39+
uses: "actions/[email protected].4"
3640
with:
37-
path: |
38-
~/.composer/cache
39-
vendor
40-
key: "php-${{ matrix.php-version }}-${{ matrix.dependencies }}"
41-
restore-keys: "php-${{ matrix.php-version }}-${{ matrix.dependencies }}"
41+
path: ${{ steps.composer-cache.outputs.dir }}
42+
key: "php-${{ matrix.php-version }}-composer-${{ matrix.dependencies }}-${{ hashFiles('**/composer.lock') }}"
43+
restore-keys: "php-${{ matrix.php-version }}-composer-${{ matrix.dependencies }}-"
4244

4345
- name: "Install lowest dependencies"
4446
if: ${{ matrix.dependencies == 'lowest' }}

.github/workflows/phpunit.yml

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ jobs:
1818
- "locked"
1919
- "development"
2020
php-version:
21-
- "8.0"
21+
- "8.1"
2222
operating-system:
2323
- "ubuntu-latest"
2424

@@ -33,14 +33,16 @@ jobs:
3333
ini-values: memory_limit=-1
3434
tools: composer:v2, cs2pr
3535

36+
- name: Get composer cache directory
37+
id: composer-cache
38+
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
39+
3640
- name: "Cache dependencies"
37-
uses: "actions/[email protected].2"
41+
uses: "actions/[email protected].4"
3842
with:
39-
path: |
40-
~/.composer/cache
41-
vendor
42-
key: "php-${{ matrix.php-version }}-${{ matrix.dependencies }}"
43-
restore-keys: "php-${{ matrix.php-version }}-${{ matrix.dependencies }}"
43+
path: ${{ steps.composer-cache.outputs.dir }}
44+
key: "php-${{ matrix.php-version }}-composer-${{ matrix.dependencies }}-${{ hashFiles('**/composer.lock') }}"
45+
restore-keys: "php-${{ matrix.php-version }}-composer-${{ matrix.dependencies }}-"
4446

4547
- name: "Install lowest dependencies"
4648
if: ${{ matrix.dependencies == 'lowest' }}

.github/workflows/static-analysis.yml

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
dependencies:
1616
- "locked"
1717
php-version:
18-
- "8.0"
18+
- "8.1"
1919
operating-system:
2020
- "ubuntu-latest"
2121

@@ -31,14 +31,16 @@ jobs:
3131
ini-values: memory_limit=-1
3232
tools: composer:v2, cs2pr
3333

34+
- name: Get composer cache directory
35+
id: composer-cache
36+
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
37+
3438
- name: "Cache dependencies"
35-
uses: "actions/[email protected].2"
39+
uses: "actions/[email protected].4"
3640
with:
37-
path: |
38-
~/.composer/cache
39-
vendor
40-
key: "php-${{ matrix.php-version }}-${{ matrix.dependencies }}"
41-
restore-keys: "php-${{ matrix.php-version }}-${{ matrix.dependencies }}"
41+
path: ${{ steps.composer-cache.outputs.dir }}
42+
key: "php-${{ matrix.php-version }}-composer-${{ matrix.dependencies }}-${{ hashFiles('**/composer.lock') }}"
43+
restore-keys: "php-${{ matrix.php-version }}-composer-${{ matrix.dependencies }}-"
4244

4345
- name: "Install lowest dependencies"
4446
if: ${{ matrix.dependencies == 'lowest' }}

Makefile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,12 @@ vendor/composer/installed.json: composer.json composer.lock
1212

1313
.PHONY: phpunit
1414
phpunit:
15-
@vendor/bin/phpunit --testsuite=unit
15+
@php -d zend.assertions=1 vendor/bin/phpunit --testsuite=unit
1616

1717
.PHONY: infection
1818
infection:
19-
@vendor/bin/phpunit --testsuite=unit --coverage-xml=build/coverage-xml --log-junit=build/junit.xml $(PHPUNIT_FLAGS)
20-
@vendor/bin/infection -s --threads=$(PARALLELISM) --coverage=build $(INFECTION_FLAGS)
19+
@php -d zend.assertions=1 -d xdebug.mode=coverage vendor/bin/phpunit --testsuite=unit --coverage-xml=build/coverage-xml --log-junit=build/junit.xml $(PHPUNIT_FLAGS)
20+
@php -d zend.assertions=1 vendor/bin/infection -s --threads=$(PARALLELISM) --coverage=build $(INFECTION_FLAGS)
2121

2222
.PHONY: phpcbf
2323
phpcbf:

behat.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
default:
2+
gherkin:
3+
filters:
4+
tags: ~@wip
5+
6+
suites:
7+
acceptance:
8+
contexts: []

composer.json

Lines changed: 16 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -11,23 +11,29 @@
1111
],
1212
"config": {
1313
"preferred-install": "dist",
14-
"sort-packages": true
14+
"sort-packages": true,
15+
"allow-plugins": {
16+
"dealerdirect/phpcodesniffer-composer-installer": true,
17+
"infection/extension-installer": true,
18+
"phpstan/extension-installer": true
19+
}
1520
},
1621
"require": {
17-
"php-64bit": "^8.0",
22+
"php-64bit": "^8.1",
1823
"ext-pcntl": "*",
19-
"psr/log": "^1.1",
24+
"psr/log": "^3.0",
2025
"react/socket": "^1.6"
2126
},
2227
"require-dev": {
23-
"infection/infection": "^0.23",
24-
"lcobucci/coding-standard": "^7.0",
25-
"monolog/monolog": "^2.2",
28+
"behat/behat": "^3.11",
29+
"infection/infection": "^0.26",
30+
"lcobucci/coding-standard": "^8.0",
31+
"monolog/monolog": "^3.2",
2632
"phpstan/extension-installer": "^1.1",
27-
"phpstan/phpstan": "^0.12",
28-
"phpstan/phpstan-deprecation-rules": "^0.12",
29-
"phpstan/phpstan-phpunit": "^0.12",
30-
"phpstan/phpstan-strict-rules": "^0.12",
33+
"phpstan/phpstan": "^1.8",
34+
"phpstan/phpstan-deprecation-rules": "^1.0",
35+
"phpstan/phpstan-phpunit": "^1.1",
36+
"phpstan/phpstan-strict-rules": "^1.3",
3137
"phpunit/phpunit": "^9.5"
3238
},
3339
"autoload": {

0 commit comments

Comments
 (0)