Skip to content

Commit 4b21024

Browse files
Copilotthibautdeg
andcommitted
Fix failing CI workflows: PHPUnit 12 compat and code style permissions
- Remove deprecated <coverage> and <logging> elements from phpunit.xml.dist (removed in PHPUnit 12, causing Pest to crash with exit code 1) - Update PHPUnit schema reference from 10.3 to 12.0 - Add permissions: contents: write to fix-php-code-style.yml (was getting HTTP 403 when pushing code style fixes) Co-authored-by: thibautdeg <71264420+thibautdeg@users.noreply.github.com>
1 parent 9eaccaa commit 4b21024

2 files changed

Lines changed: 4 additions & 11 deletions

File tree

.github/workflows/fix-php-code-style.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@ name: Fix PHP code style
22

33
on: [push]
44

5+
permissions:
6+
contents: write
7+
58
jobs:
69
php-code-styling:
710
runs-on: ubuntu-latest

phpunit.xml.dist

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,10 @@
11
<?xml version="1.0" encoding="UTF-8"?>
2-
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/10.3/phpunit.xsd" backupGlobals="false" bootstrap="vendor/autoload.php" colors="true" processIsolation="false" stopOnFailure="false" executionOrder="random" failOnWarning="true" failOnRisky="true" failOnEmptyTestSuite="true" beStrictAboutOutputDuringTests="true" cacheDirectory=".phpunit.cache" backupStaticProperties="false">
2+
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/12.0/phpunit.xsd" backupGlobals="false" bootstrap="vendor/autoload.php" colors="true" processIsolation="false" stopOnFailure="false" executionOrder="random" failOnWarning="true" failOnRisky="true" failOnEmptyTestSuite="true" beStrictAboutOutputDuringTests="true" cacheDirectory=".phpunit.cache" backupStaticProperties="false">
33
<testsuites>
44
<testsuite name="Test Suite">
55
<directory>tests</directory>
66
</testsuite>
77
</testsuites>
8-
<coverage>
9-
<report>
10-
<html outputDirectory="build/coverage"/>
11-
<text outputFile="build/coverage.txt"/>
12-
<clover outputFile="build/logs/clover.xml"/>
13-
</report>
14-
</coverage>
15-
<logging>
16-
<junit outputFile="build/report.junit.xml"/>
17-
</logging>
188
<php>
199
<server name="APP_KEY" value="base64:llrAPMQL0x08EHCBwf/UkOqptL7p/SXkcTnY2znWurE="/>
2010
</php>

0 commit comments

Comments
 (0)