Skip to content

Commit

Permalink
Update to PHPUnit 10, add PHP HTTP-Plug support
Browse files Browse the repository at this point in the history
  • Loading branch information
bennothommo committed Apr 9, 2024
1 parent 7ae60ad commit 0770bc1
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 30 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,6 @@
/vendor/
/.phpunit.cache/
/coverage/

# PHPUnit ignores
.phpunit.result.cache
17 changes: 13 additions & 4 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,19 @@
"ext-zip": "*",
"ext-zlib": "*",
"composer/composer": "^2.7.0",
"php-http/discovery": "^1.0",
"php-http/httplug": "^2.0",
"php-http/message-factory": "^1.0",
"psr/http-client-implementation": "^1.0",
"psr/http-message": "^1.0",
"symfony/process": "^4.3.4 || ^5.0 || ^6.0"
},
"require-dev": {
"dms/phpunit-arraysubset-asserts": "^0.4.0",
"nyholm/psr7": "^1.8",
"symfony/http-client": "^7.0",
"php-http/message": "^1.0",
"phpstan/phpstan": "^1.6",
"phpunit/phpunit": "^8.5.15 || ^9.5.4",
"symfony/phpunit-bridge": "^4.3.4 || ^5.0 || ^6.0"
"phpunit/phpunit": "^10.5"
},
"autoload": {
"psr-4": {
Expand All @@ -51,6 +57,9 @@
"prefer-stable": true,
"minimum-stability": "dev",
"config": {
"sort-packages": true
"sort-packages": true,
"allow-plugins": {
"php-http/discovery": true
}
}
}
37 changes: 11 additions & 26 deletions phpunit.xml.dist
Original file line number Diff line number Diff line change
@@ -1,28 +1,13 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.5/phpunit.xsd"
bootstrap="vendor/autoload.php"
cacheResultFile=".phpunit.cache/test-results"
executionOrder="depends,defects"
forceCoversAnnotation="true"
beStrictAboutCoversAnnotation="true"
beStrictAboutOutputDuringTests="true"
beStrictAboutTodoAnnotatedTests="true"
failOnWarning="true"
>
<testsuites>
<testsuite name="Test Suite">
<directory suffix="Test.php">tests</directory>
</testsuite>
</testsuites>

<coverage
cacheDirectory=".phpunit.cache/code-coverage"
processUncoveredFiles="true"
>
<include>
<directory suffix=".php">src</directory>
</include>
</coverage>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/10.5/phpunit.xsd" bootstrap="vendor/autoload.php" executionOrder="depends,defects" beStrictAboutOutputDuringTests="true" failOnWarning="true" cacheDirectory=".phpunit.cache" requireCoverageMetadata="true" beStrictAboutCoverageMetadata="true">
<testsuites>
<testsuite name="Test Suite">
<directory suffix="Test.php">tests</directory>
</testsuite>
</testsuites>
<source>
<include>
<directory suffix=".php">src</directory>
</include>
</source>
</phpunit>

0 comments on commit 0770bc1

Please sign in to comment.