Skip to content

Commit

Permalink
Add phpunit configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
paulbalandan committed Jul 29, 2024
1 parent 54e8007 commit fae00b9
Show file tree
Hide file tree
Showing 3 changed files with 41 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@
/.php-cs-fixer.php
/composer.lock
/phpstan.neon
/phpunit.xml
4 changes: 3 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,13 @@
"php": "^8.2"
},
"require-dev": {
"nexusphp/tachycardia": "^2.3",
"phpstan/extension-installer": "^1.4",
"phpstan/phpstan": "^1.11",
"phpstan/phpstan-deprecation-rules": "^1.2",
"phpstan/phpstan-phpunit": "^1.4",
"phpstan/phpstan-strict-rules": "^1.6"
"phpstan/phpstan-strict-rules": "^1.6",
"phpunit/phpunit": "^11.2"
},
"minimum-stability": "dev",
"prefer-stable": true,
Expand Down
37 changes: 37 additions & 0 deletions phpunit.xml.dist
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/11.2/phpunit.xsd"
bootstrap="vendor/autoload.php"
cacheDirectory="build/.phpunit.cache"
colors="true"
columns="max"
executionOrder="random"
requireCoverageMetadata="true"
beStrictAboutCoverageMetadata="true"
beStrictAboutChangesToGlobalState="true"
beStrictAboutOutputDuringTests="true"
failOnRisky="true"
failOnWarning="true">
<testsuites>
<testsuite name="Nexus Test Suite">
<directory suffix="Test.php">tests/</directory>
</testsuite>
</testsuites>

<source ignoreIndirectDeprecations="true" restrictNotices="true" restrictWarnings="true">
<include>
<directory>src/Nexus/</directory>
</include>
</source>

<php>
<ini name="date.timezone" value="UTC" />
<ini name="memory_limit" value="-1" />
</php>

<extensions>
<bootstrap class="Nexus\PHPUnit\Tachycardia\TachycardiaExtension">
<parameter name="precision" value="2" />
</bootstrap>
</extensions>
</phpunit>

0 comments on commit fae00b9

Please sign in to comment.