From: Timo Tijhof Date: Sat, 13 Feb 2016 14:00:20 +0000 (+0100) Subject: Upgrade from PHPunit 3.7.x to PHPUnit 4.8.x X-Git-Tag: 1.31.0-rc.0~7868^2 X-Git-Url: http://git.cyclocoop.org/%22%20.%20generer_url_ecrire%28%22lang_raccourcis%22%2C%22module=%24nom_module%22%29%20.%20%22?a=commitdiff_plain;h=dbe3499113feaf3192fc4efcedfccda13b151767;p=lhc%2Fweb%2Fwiklou.git Upgrade from PHPunit 3.7.x to PHPUnit 4.8.x Major changes: * (4.0.0) Limited support for stubbing and mocking static methods was removed. (introduced in PHPUnit 3.5) * (4.0.0) The addRiskyTest() was added to the PHPUnit_Framework_TestListener interface. Classes that implement this interface MUST implement this method. * (4.5.0) The "--strict" catch-all option was deprecated. Use specific options instead. Notable changes: * (4.6.0) Tests not annotated with @small, @medium, or @large are no longer default to matching in group @small. * (4.6.0) Result printer now checks hasColorSupport(). * (4.8.0) The name of the default group was changed from "__nogroup__" to "default". * (4.8.0) This is the last release to support PHP 5.3, PHP 5.4, and PHP 5.5. PHPUnit 5 will require PHP 5.6 or higher. PHPUnit 3.7.17 was released March 2013. PHPUnit 4.8.0 was released August 2015. PHPUnit 4.8.23 was released January 2016. Details: * https://github.com/sebastianbergmann/phpunit/wiki/ChangeLog-for-PHPUnit-3.7 * https://github.com/sebastianbergmann/phpunit/wiki/Release-Announcement-for-PHPUnit-4.0.0 * https://github.com/sebastianbergmann/phpunit/wiki/Release-Announcement-for-PHPUnit-4.1.0 * https://github.com/sebastianbergmann/phpunit/wiki/Release-Announcement-for-PHPUnit-4.2.0 * https://github.com/sebastianbergmann/phpunit/wiki/Release-Announcement-for-PHPUnit-4.3.0 * https://github.com/sebastianbergmann/phpunit/wiki/Release-Announcement-for-PHPUnit-4.4.0 * https://github.com/sebastianbergmann/phpunit/wiki/Release-Announcement-for-PHPUnit-4.5.0 * https://github.com/sebastianbergmann/phpunit/wiki/Release-Announcement-for-PHPUnit-4.6.0 * https://github.com/sebastianbergmann/phpunit/wiki/Release-Announcement-for-PHPUnit-4.7.0 * https://github.com/sebastianbergmann/phpunit/wiki/Release-Announcement-for-PHPUnit-4.8.0 Bug: T99982 Change-Id: I70ad81513812aa76a84fa55be14135aac94d55e8 --- diff --git a/composer.json b/composer.json index c5b4395a4a..12703111f2 100644 --- a/composer.json +++ b/composer.json @@ -45,7 +45,7 @@ "monolog/monolog": "~1.17.2", "nikic/php-parser": "1.4.1", "nmred/kafka-php": "0.1.5", - "phpunit/phpunit": "3.7.37", + "phpunit/phpunit": "4.8.23", "wikimedia/avro": "1.7.7" }, "suggest": { diff --git a/tests/phpunit/phpunit.php b/tests/phpunit/phpunit.php index 66e8182172..86fc295ded 100755 --- a/tests/phpunit/phpunit.php +++ b/tests/phpunit/phpunit.php @@ -176,19 +176,6 @@ class PHPUnitMaintClass extends Maintenance { $_SERVER['argv'] = array_values( $_SERVER['argv'] ); } - if ( !wfIsWindows() ) { - # If we are not running on windows then we can enable phpunit colors - # Windows does not come anymore with ANSI.SYS loaded by default - # PHPUnit uses the suite.xml parameters to enable/disable colors - # which can be then forced to be enabled with --colors. - # The below code injects a parameter just like if the user called - # Probably fix bug 29226 - $key = array_search( '--colors', $_SERVER['argv'] ); - if ( $key === false ) { - array_splice( $_SERVER['argv'], 1, 0, '--colors' ); - } - } - # Makes MediaWiki PHPUnit directory includable so the PHPUnit will # be able to resolve relative files inclusion such as suites/* # PHPUnit uses stream_resolve_include_path() internally diff --git a/tests/phpunit/suite.xml b/tests/phpunit/suite.xml index bdabdc1fcf..63f5de0179 100644 --- a/tests/phpunit/suite.xml +++ b/tests/phpunit/suite.xml @@ -1,11 +1,9 @@ - -