mirror of
git://develop.git.wordpress.org/
synced 2025-01-17 12:58:25 +01:00
aae784273f
Now that the tests can run PHPUnit cross-version and Composer will be used to install the test suite in CI, we could switch out the local copies of the [https://github.com/johnkary/phpunit-speedtrap PHPUnit speedtrap] package in favor of using the Composer package, which would prevent us having to make the WP local copies of the class compatible with later PHPUnit versions. The SpeedTrap test listener was introduced to identify slow tests and take action on these to make them faster. In practice, however, no notable action was ever taken based on the output of the test listener in all the years it was in place. With that in mind, it was decided to remove the SpeedTrap test listeners without replacement. If – at a future date – contributors would want to take action to speed up slow tests anyway, they can: * Either add the package to their local install and use the output they receive locally to identify slow tests. * Or use the PHPUnit native `@small` annotations in combination with the PHPUnit `PHP_Invoker` package as described in the PHPUnit documentation to [https://phpunit.readthedocs.io/en/stable/risky-tests.html#test-execution-timeout run tests with time limits]. Follow-up to [35214], [35226], [35767], [44701], [51559-51572]. Props jrf. See #46149. git-svn-id: https://develop.svn.wordpress.org/trunk@51573 602fd350-edb4-49c9-b593-d223f7449a82
70 lines
2.5 KiB
XML
70 lines
2.5 KiB
XML
<phpunit
|
|
bootstrap="tests/phpunit/includes/bootstrap.php"
|
|
backupGlobals="false"
|
|
colors="true"
|
|
beStrictAboutTestsThatDoNotTestAnything="true"
|
|
>
|
|
<testsuites>
|
|
<!-- Default test suite to run all tests. -->
|
|
<testsuite name="default">
|
|
<directory suffix=".php">tests/phpunit/tests</directory>
|
|
<exclude>tests/phpunit/tests/rest-api/rest-autosaves-controller.php</exclude>
|
|
</testsuite>
|
|
<!-- Sets the DOING_AUTOSAVE constant, so needs to be run last. -->
|
|
<testsuite name="restapi-autosave">
|
|
<file>tests/phpunit/tests/rest-api/rest-autosaves-controller.php</file>
|
|
</testsuite>
|
|
</testsuites>
|
|
<groups>
|
|
<exclude>
|
|
<group>ajax</group>
|
|
<group>ms-files</group>
|
|
<group>ms-required</group>
|
|
<group>external-http</group>
|
|
</exclude>
|
|
</groups>
|
|
<logging>
|
|
<log type="junit" target="tests/phpunit/build/logs/junit.xml" />
|
|
</logging>
|
|
<php>
|
|
<const name="WP_RUN_CORE_TESTS" value="1" />
|
|
</php>
|
|
<filter>
|
|
<whitelist addUncoveredFilesFromWhitelist="true">
|
|
<directory suffix=".php">src</directory>
|
|
<exclude>
|
|
<!-- Third party library exclusions. -->
|
|
<directory suffix=".php">src/wp-includes/ID3</directory>
|
|
<directory suffix=".php">src/wp-includes/IXR</directory>
|
|
<directory suffix=".php">src/wp-includes/random_compat</directory>
|
|
<directory suffix=".php">src/wp-includes/PHPMailer</directory>
|
|
<directory suffix=".php">src/wp-includes/Requests</directory>
|
|
<directory suffix=".php">src/wp-includes/SimplePie</directory>
|
|
<directory suffix=".php">src/wp-includes/sodium_compat</directory>
|
|
<directory suffix=".php">src/wp-includes/Text</directory>
|
|
|
|
<!-- Plugins and themes. -->
|
|
<directory suffix=".php">src/wp-content/</directory>
|
|
|
|
<file>src/wp-admin/includes/class-ftp*</file>
|
|
<file>src/wp-admin/includes/class-pclzip.php</file>
|
|
<file>src/wp-admin/includes/deprecated.php</file>
|
|
<file>src/wp-admin/includes/ms-deprecated.php</file>
|
|
|
|
<file>src/wp-includes/atomlib.php</file>
|
|
<file>src/wp-includes/class-IXR.php</file>
|
|
<file>src/wp-includes/class-json.php</file>
|
|
<file>src/wp-includes/class-phpass.php</file>
|
|
<file>src/wp-includes/class-pop3.php</file>
|
|
<file>src/wp-includes/class-requests.php</file>
|
|
<file>src/wp-includes/class-simplepie.php</file>
|
|
<file>src/wp-includes/class-snoopy.php</file>
|
|
<file>src/wp-includes/deprecated.php</file>
|
|
<file>src/wp-includes/ms-deprecated.php</file>
|
|
<file>src/wp-includes/pluggable-deprecated.php</file>
|
|
<file>src/wp-includes/rss.php</file>
|
|
</exclude>
|
|
</whitelist>
|
|
</filter>
|
|
</phpunit>
|