fixes 8 bugs in /phase3/t/ tests
The tests in /phase3/t/inc have been broken for a while. The attached patch (merged, diffed and tested against r54593) fixes all of the tests in that directory. The patch is relative to /phase3/t/. Getting all tests to work required fixing 8 bugs. Note: the test file Parser.t still returns one failure. That is because Parser.t simply involkes parserTests and parserTests currently reports one failed test. So, this failure is not a bug in Parser.t.
The following files are affected by this patch:
- fixed bug in t/Search.inc: the database prefix was incorrect. Added a "_" suffix so Search.t works.
- fixed by in t/inc/Database.t: Moved up require of LocalSettings.php, because its definitions are now required by Autoloader.php.
- fixed bug in t/inc/Global.t: Moved up require of LocalSettings.php, because its definitions are now required by Autoloader.php.
- fixed bug in IP.t: increased plan number from 1010 to 1120.
- fixed bug in Language.t: changed data constants in array initialization from floats to strings. Specifying them as floats was causing round-off error problems. In addition userAdjust expects its arguments to be strings.
- fixed bug in LocalFile.t: changed expected result from getThumbVirtualUrl() to reflect new directory organization for filerepos (specifically, virtual thumbs are in /test/thumb not /test/public/thumb.
- fixed bug in Revision.t: added require of LocalSettings.php and require_once of LocalisationCache.php. LocalisationCache.php requires some of the definitions in LocalSettings.php. LocalisationCache.php is required so Language::factory( 'en' ) works.
- fixed bug in Title.t: deleted the ">" character in the strpos() call so ">" tests as legal in page titles. The addition of ">" to $wgLegalTitleChars in DefaultSettings.php occured in r53667.
To verify that the tests now run correctly, cd to /phase3/ and execute 'prove t/inc -r' (assumes tester has the prove application installed).