Files
pl_mail/phpunit.dist.xml
Svenandpmdevelopment 55a6d67a48 Give the PHP time limit back after every test (#89)
A streaming controller's set_time_limit() outlived its test in the single PHPUnit process and killed slower runs part-way. A PHPUnit extension resets it after every test.

Co-authored-by: pmdevelopment <4947485+pmdevelopment@users.noreply.github.com>
2026-10-15 14:49:28 +02:00

61 lines
2.5 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<!-- https://phpunit.readthedocs.io/en/latest/configuration.html -->
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="vendor/phpunit/phpunit/phpunit.xsd"
colors="true"
failOnDeprecation="true"
failOnNotice="true"
failOnWarning="true"
bootstrap="tests/bootstrap.php"
cacheDirectory=".phpunit.cache"
>
<php>
<ini name="display_errors" value="1" />
<ini name="error_reporting" value="-1" />
<server name="APP_ENV" value="test" force="true" />
<!-- A file of its own: InstallEmptyInstallTest writes APP_PUBLIC_URL
through the real service, and the generated secrets the test
environment actually runs on must not be the thing it overwrites. -->
<server name="APP_SECRETS_FILE" value="var/secrets/phpunit.env" force="true" />
<server name="SHELL_VERBOSITY" value="-1" />
<!-- Most tests here are plain unit tests, but the filter-agreement
test boots the kernel: it has to execute the compiler's SQL
against a real Postgres, which is the whole point of it. -->
<server name="KERNEL_CLASS" value="App\Kernel" />
</php>
<!-- tests/ holds both suites: PHPUnit mirrors src/ by path, Playwright owns
tests/e2e (see playwright.config.ts). The exclusion is what keeps that
split deliberate rather than relying on .ts files never matching the
*Test.php suffix. -->
<testsuites>
<testsuite name="Project Test Suite">
<directory>tests</directory>
<exclude>tests/e2e</exclude>
</testsuite>
</testsuites>
<source ignoreSuppressionOfDeprecations="true"
ignoreIndirectDeprecations="true"
restrictNotices="true"
restrictWarnings="true"
>
<include>
<directory>src</directory>
</include>
<deprecationTrigger>
<method>Doctrine\Deprecations\Deprecation::trigger</method>
<method>Doctrine\Deprecations\Deprecation::delegateTriggerToBackend</method>
<function>trigger_deprecation</function>
</deprecationTrigger>
</source>
<extensions>
<!-- The streaming controllers call set_time_limit(), and in one
PHPUnit process that limit outlives their test. See the class. -->
<bootstrap class="App\Tests\Support\PhpUnit\ResetTimeLimitExtension"/>
</extensions>
</phpunit>