Commit graph

17 commits

Author SHA1 Message Date
Christian Aistleitner
096592cf14 Bumping minimum supported version of PHPUnit to 3.6.7
With PHPUnit 3.6.7, we can finally check the output of tests.

Change-Id: Ib0f1afe5fd9ab9784ba7f78b2921cf047ccc83f3
2012-04-29 10:02:23 +02:00
Antoine Musso
3b9a3678b3 let us easily override PHPUnit version
The new --with-phpunitdir let us specify a git checkout of PHPUnit. That
will ease regression testing of the upstream new version. Usage is
straightforward:

Checkout PHPUnit from git as instructed on:
https://github.com/sebastianbergmann/phpunit#readme

Invoke our test suite with:
 $ cd maintenance/tests
 $ php phpunit.php --with-phpunitdir /path/you/just/checked/out

Change-Id: I8a9af0deac4dd74e3c8bde73535555c54ac83766
2012-04-17 15:39:15 +02:00
Aaron Schulz
10f49bd065 [LanguageConverter] Added some cache code based on the problems in r97512.
* Added $wgLanguageConverterCacheType global to control LC cache type. We can use it to enable direct apc use for language converter (to match the live hack).
* Added $wgLangConvMemc object, available via Setup.php

Change 1:
* Updated unit tests
* Minor documentation cleanup in DefaultSettings.php

Change-Id: Icd5dd28407e9759ce294c784ec41d9ca15c89616
2012-04-06 13:26:17 -07:00
Tim Starling
2462a1ae71 Make arguments to phpunit.php work. It's hard to believe this could have been broken since r79164, so maybe it was a change in the command line parser that PHPUnit uses that made it treat any options after the first non-option argument as being plain arguments rather than actual options. 2012-01-23 19:06:09 +00:00
Max Semenik
6016958c3c To prevent creepy errors like bug 28908, raised PHPUnit requirement to 3.5 2011-05-10 19:45:47 +00:00
Platonides
f80b75a6aa The $wgLocalisationCacheConf was being overwritten by the default value.
Restores the ability to run databaseless tests broken by r86775
2011-04-29 16:26:20 +00:00
Sam Reed
8e80b8c3c1 Tidy up some unused variables and such 2011-04-23 21:40:52 +00:00
Platonides
4ef087080d maintenance/commandLine.inc loads DefaultSettings, LocalSettings and then runs Setup.php
As Setup.php assigns variables based on the cache config, bootstrap.php was late on reseting them, as some objects were already created.
So we could end up with a SqlBagOStuff created there, which when later accessed (such as trying to invalidate the cache for a user) would 
-as any non-sqlite SqlBagOStuff- open a new db connection. Which is precisely what we shall not be done when dealing with temporary tables
(and would indeed fail miserably due to not finding unittest_objectcache table).

In summary, reenabling temporary tables disabled in r79411.
2011-02-21 23:19:26 +00:00
Platonides
71ee20cd18 Move $wgLocalisationCacheConf disabling from bootstrap.php to phpunit.php 2011-01-21 22:44:40 +00:00
Platonides
f78ae2a51a Use an autoloader for the tests, following the ideas from r72858.
The SeleniumTestConstants class was added in r79437
2011-01-01 22:04:14 +00:00
Platonides
439b5a4f65 Follow up r79183 removing global added in r79154 2010-12-29 16:45:16 +00:00
Platonides
4cb81e08f4 Move MediaWikiTestCase class to a new file and load it from phpunit.php
This restores the ability to run single tests with 
php phpunit.php includes/filename.php
2010-12-29 15:52:07 +00:00
X!
fa0ce7197a -Set configuration automatically if not set. This allows for evasion of the makefile, ergo, more control.
-Remove instances of @covers; they were breaking code-coverage
2010-12-29 05:38:11 +00:00
X!
edbf743aeb Make MediaWikiParserTest work now in PHPUnit. There are still a few bugs, such as stopping tests if one fails,
lack of fuzz testing and other parser test options, and the DB creation is still a little flaky.
A MediaWikiPHPUnitCommand class had to be created to allow for custom CLI parameters.
2010-12-29 02:23:51 +00:00
Happy-melon
8e57be2831 Follow-up r77762 per CR, and an unrelated one-character whitespace fix which doesn't deserve its own revision id... :D 2010-12-16 18:30:15 +00:00
Mark A. Hershberger
640f12cd5e Repair phpunit.php 2010-12-16 01:32:28 +00:00
Chad Horohoe
23f69f10ed Per wikitech-l discussion: Move tests from maintenance/tests/ to tests/. They're not strictly maintenance scripts, and some people want to do a selective checkout that doesn't include the tests. There's still debate on whether we should include these in the release downloads, but we had a pretty firm consensus to move this. 2010-12-14 16:26:35 +00:00