CluPilotCloud/phpunit.xml

53 lines
2.6 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="vendor/phpunit/phpunit/phpunit.xsd"
bootstrap="vendor/autoload.php"
colors="true"
>
<testsuites>
<testsuite name="Unit">
<directory>tests/Unit</directory>
</testsuite>
<testsuite name="Feature">
<directory>tests/Feature</directory>
</testsuite>
</testsuites>
<source>
<include>
<directory>app</directory>
</include>
</source>
<php>
<!-- force=true so these override the dev .env that docker-compose injects
as real container env vars (otherwise tests use redis/mariadb). -->
<env name="APP_ENV" value="testing" force="true"/>
<!-- Pinned so the suite never depends on the operator's real hostnames:
route() builds URLs from APP_URL, and a deployment-specific
ADMIN_HOSTS would then 404 every admin route. Tests that exercise
the restriction set admin_access.hosts themselves. -->
<env name="APP_URL" value="http://localhost" force="true"/>
<env name="ADMIN_HOSTS" value="" force="true"/>
<!-- Fixed test key: storing a VPN config must be exercised, and a
random one would make a decryption failure irreproducible. -->
<env name="VPN_CONFIG_KEY" value="Y2x1cGlsb3QtdGVzdC1vbmx5LXZwbi1rZXktMzJieXQ=" force="true"/>
<!-- Blank so the suite never picks up the operator's real webhook secret
from .env: with one set, every unsigned test payload is rejected as
an invalid signature. The two tests that DO exercise verification
set the secret themselves. -->
<env name="STRIPE_WEBHOOK_SECRET" value="" force="true"/>
<env name="APP_MAINTENANCE_DRIVER" value="file"/>
<env name="BCRYPT_ROUNDS" value="4" force="true"/>
<env name="BROADCAST_CONNECTION" value="null" force="true"/>
<env name="CACHE_STORE" value="array" force="true"/>
<env name="DB_CONNECTION" value="sqlite" force="true"/>
<env name="DB_DATABASE" value=":memory:" force="true"/>
<env name="DB_URL" value="" force="true"/>
<env name="MAIL_MAILER" value="array" force="true"/>
<env name="QUEUE_CONNECTION" value="sync" force="true"/>
<env name="SESSION_DRIVER" value="array" force="true"/>
<env name="PULSE_ENABLED" value="false"/>
<env name="TELESCOPE_ENABLED" value="false"/>
<env name="NIGHTWATCH_ENABLED" value="false"/>
</php>
</phpunit>