mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-03-30 18:24:31 +00:00
Build/Test Tools: Add support for PHPUnit 6+.
This adds a compatibility shim for the new namespaced structure of PHPUnit and the removed `setExpectedException()` method. In addition, this updates the Travis config so PHPUnit 6.1 is used where appropriate. Props miyauchi, gitlost. Fixes #39822 git-svn-id: https://develop.svn.wordpress.org/trunk@40536 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -3,6 +3,12 @@
|
||||
* Installs WordPress for running the tests and loads WordPress and the test libraries
|
||||
*/
|
||||
|
||||
/**
|
||||
* Compatibility with PHPUnit 6+
|
||||
*/
|
||||
if ( class_exists( 'PHPUnit\Runner\Version' ) ) {
|
||||
require_once dirname( __FILE__ ) . '/phpunit6-compat.php';
|
||||
}
|
||||
|
||||
$config_file_path = dirname( dirname( __FILE__ ) );
|
||||
if ( ! file_exists( $config_file_path . '/wp-tests-config.php' ) ) {
|
||||
|
||||
Reference in New Issue
Block a user