From d417de70fcf39e0a7a15ba780b597914d16ca0f7 Mon Sep 17 00:00:00 2001 From: Pierre Schmitz Date: Wed, 12 Mar 2014 18:12:23 +0100 Subject: Update to MediaWiki 1.22.4 --- tests/phpunit/structure/StructureTest.php | 63 ------------------------------- 1 file changed, 63 deletions(-) delete mode 100644 tests/phpunit/structure/StructureTest.php (limited to 'tests/phpunit/structure/StructureTest.php') diff --git a/tests/phpunit/structure/StructureTest.php b/tests/phpunit/structure/StructureTest.php deleted file mode 100644 index df00d4df..00000000 --- a/tests/phpunit/structure/StructureTest.php +++ /dev/null @@ -1,63 +0,0 @@ -markTestSkipped( 'This test does not work on Windows' ); - } - $rootPath = escapeshellarg( __DIR__ . '/..' ); - $testClassRegex = implode( '|', array( - 'ApiFormatTestBase', - 'ApiTestCase', - 'ApiQueryTestBase', - 'ApiQueryContinueTestBase', - 'MediaWikiLangTestCase', - 'MediaWikiTestCase', - 'PHPUnit_Framework_TestCase', - 'DumpTestCase', - ) ); - $testClassRegex = "^class .* extends ($testClassRegex)"; - $finder = "find $rootPath -name '*.php' '!' -name '*Test.php'" . - " | xargs grep -El '$testClassRegex|function suite\('"; - - $results = null; - $exitCode = null; - exec( $finder, $results, $exitCode ); - - $this->assertEquals( - 0, - $exitCode, - 'Verify find/grep command succeeds.' - ); - - $results = array_filter( - $results, - array( $this, 'filterSuites' ) - ); - $strip = strlen( $rootPath ) - 1; - foreach ( $results as $k => $v ) { - $results[$k] = substr( $v, $strip ); - } - $this->assertEquals( - array(), - $results, - "Unit test file in $rootPath must end with Test." - ); - } - - /** - * Filter to remove testUnitTestFileNamesEndWithTest false positives. - */ - public function filterSuites( $filename ) { - return strpos( $filename, __DIR__ . '/../suites/' ) !== 0; - } -} -- cgit v1.2.2