Last active
May 27, 2019 11:26
-
-
Save kamaroly/dc066efde6a2a485e24c6915412e1f09 to your computer and use it in GitHub Desktop.
WordPress plugin phpunit.xml for easy unit testing in WordPress plugin development. Put your tests in `tests` folder in your plugins
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<phpunit backupGlobals="false" | |
backupStaticAttributes="false" | |
bootstrap="../../../wp-load.php" | |
colors="true" | |
convertErrorsToExceptions="true" | |
convertNoticesToExceptions="true" | |
convertWarningsToExceptions="true" | |
processIsolation="false" | |
stopOnFailure="false"> | |
<testsuites> | |
<testsuite name="Application Test Suite"> | |
<directory suffix="Test.php">./tests</directory> | |
</testsuite> | |
</testsuites> | |
<php> | |
<env name="APP_ENV" value="testing"/> | |
<env name="CACHE_DRIVER" value="array"/> | |
<env name="DB_CONNECTION" value="sqlite"/> | |
<env name="DB_DATABASE" value=":memory:"/> | |
<env name="SESSION_DRIVER" value="array"/> | |
<env name="QUEUE_DRIVER" value="sync"/> | |
</php> | |
</phpunit> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment