Skip to content

Commit aa9e5af

Browse files
authored
Merge pull request #21 from andrew-demb/patch-3
Green CI (modern phpunit config, drop not needed ignoring requirements, phpcsfixer 3)
2 parents fe56c80 + 0375366 commit aa9e5af

4 files changed

Lines changed: 21 additions & 19 deletions

File tree

.github/workflows/grumphp.yaml

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -35,12 +35,6 @@ jobs:
3535
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }}
3636
restore-keys: ${{ runner.os }}-composer-
3737
- name: Install dependencies PHP
38-
run: composer update --prefer-dist --no-progress --no-suggest ${{ matrix.composer-options }} --ignore-platform-reqs
39-
- name: Set git variables
40-
run: |
41-
git config --global user.email "you@example.com"
42-
git config --global user.name "Your Name"
38+
run: composer update --prefer-dist --no-progress --no-suggest ${{ matrix.composer-options }}
4339
- name: Run the tests
4440
run: php vendor/bin/grumphp run --no-interaction
45-
env:
46-
PHP_CS_FIXER_IGNORE_ENV: 1

composer.json

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,15 +17,18 @@
1717
"symfony/http-kernel": "^5.3 || ^6.0"
1818
},
1919
"require-dev": {
20-
"friendsofphp/php-cs-fixer": "^3.3",
20+
"friendsofphp/php-cs-fixer": "^3.4",
2121
"matthiasnoback/symfony-dependency-injection-test": "^4.2",
2222
"phpro/grumphp-shim": "^1.6.0",
2323
"phpspec/prophecy-phpunit": "^2.0",
2424
"phpunit/phpunit": "^9.4",
2525
"symfony/security-core": "^5.3 || ^6.0"
2626
},
2727
"config": {
28-
"sort-packages": true
28+
"sort-packages": true,
29+
"allow-plugins": {
30+
"phpro/grumphp-shim": true
31+
}
2932
},
3033
"autoload": {
3134
"psr-4": {

grumphp.yml.dist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
grumphp:
22
tasks:
3-
phpcsfixer2:
3+
phpcsfixer:
44
config: ".php-cs-fixer.dist.php"
55
config_contains_finder: true
66
phpunit: ~

phpunit.xml.dist

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,21 @@
11
<?xml version="1.0" encoding="UTF-8"?>
2-
<phpunit colors="true">
2+
<phpunit
3+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4+
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.3/phpunit.xsd"
5+
colors="true"
6+
>
37
<testsuites>
48
<testsuite name="Unit">
59
<directory>./test</directory>
610
</testsuite>
711
</testsuites>
8-
<filter>
9-
<whitelist processUncoveredFilesFromWhitelist="true">
10-
<directory suffix=".php">src</directory>
11-
</whitelist>
12-
</filter>
13-
<logging>
14-
<log type="coverage-clover" target="var/coverage.xml" />
15-
</logging>
12+
13+
<coverage processUncoveredFiles="true">
14+
<include>
15+
<directory suffix=".php">src</directory>
16+
</include>
17+
<report>
18+
<clover outputFile="var/coverage.xml"/>
19+
</report>
20+
</coverage>
1621
</phpunit>

0 commit comments

Comments
 (0)