Sam Reed
6906724935
Add, update, tweak documentation
...
Fix document comment blocks
Tweak some returns
2011-10-26 03:45:13 +00:00
Antoine Musso
874ae7a731
test that preloaded text is unstripped
...
bug 27467 reported our preloaded system did not unstrip <nowiki>
or <pre> enclosed text. The fix was applied by r82473.
2011-10-24 10:51:46 +00:00
Antoine Musso
ae87825ed9
test {{SERVERNAME}} with relative URLS
...
bug 31176 mentionned an issue with {{SERVERNAME}} returning the full
URL instead of servername when using relative URLs (//localhost).
The fix was made by r98193.
This patch test three different URL protocols (http, https & relative)
and check we return the expected 'localhost'.
2011-10-24 09:32:33 +00:00
Antoine Musso
c1f23144e1
using real identity for hashar
...
Converting my pseudonym to use my real identity instead:
Ashar Voultoiz -> Antoine Musso
2011-10-24 09:08:13 +00:00
Brion Vibber
61bb13a24a
Followup r80375: let PreprocessorTest work on Preprocessor_Hash etc as well as Preprocessor_Dom
...
Using same technique as ApiExpandTemplates to serialize the object tree back to XML, rather than asking for the DOM implementation's internal XML return function.
Have to also perform normalization on the test cases, as they aren't normalized to what libxml2 serializes. :P
Note that there are 4 test failures currently with Preprocessor_Hash, as it makes a separate <equals> element around = which doesn't appear to be in Preprocessor_Dom's output.
2011-10-15 20:21:52 +00:00
Daniel Friesen
7a1d3bf06a
Followup r98056; Add to this screwed up NewParserTest phpunit stuff as well.
2011-09-26 02:04:17 +00:00
Brian Wolff
4fc3cd0b22
Make the phpunit old-style parserTest converter thingy not fall on its face if an extension registers a parserTests test file that has a period in it.
2011-09-18 03:32:43 +00:00
Aaron Schulz
23d5a27e2e
Reverted r86072, r86419 per CR. Lots of conflicts resolved here. Removes lineStart from r87346 code as well for preprocess parser tests.
2011-09-12 19:16:22 +00:00
Max Semenik
02b2c6c8db
Fix for r96344: explicitly set $wgExtensionAssetsPath during tests
2011-09-06 16:47:05 +00:00
Chad Horohoe
df19f6cdea
Merge ParserTestStaticParserHook into ParserTestParserHook since they practically do the same thing.
2011-09-06 14:46:58 +00:00
Platonides
9d98f581bb
Manually set the title as not being a redirect. Otherwise,
...
it needed a database from Parser::getFunctionLang() ->
Title::getPageLanguage() -> Title::isRedirect()
2011-08-27 21:10:41 +00:00
Brian Wolff
c909720031
Follow-up r94680 - fix unit tests.
...
The way the magic variable unit tests are run looks a little sketchy to me...
2011-08-17 00:46:58 +00:00
Chad Horohoe
1015bf5986
Followup r94678: remove some include and autoload entries. tests still passing
2011-08-16 19:25:26 +00:00
Chad Horohoe
b11588e827
Remove ParserHelpers. NewParserTest still needs some cleanup, but it doesn't rely on this. All tests still pass.
2011-08-16 19:18:07 +00:00
Alexandre Emsenhuber
062e2723ba
Some misc fixes to tests:
...
* Don't create a WebRequest instance to put in $wgRequest in test since it is meant for HTTP requests, not command line ones
* Force $wgAlwaysUseTidy to false in ExtraParserTest, having it to true breaks testBug8689() and testParse()
2011-08-16 15:17:35 +00:00
Chad Horohoe
5f8e4b019b
Move the fuzz test into @group Broken so it will shut up about being incomplete
2011-08-09 16:13:56 +00:00
Alexandre Emsenhuber
762c3f8204
* Call Linker methods statically
...
* Use INSERT IGNORE for the site_stats row (as for the interwiki entries); was throwing query error about duplicate row on my installation
2011-08-05 15:17:19 +00:00
Chad Horohoe
04b80879ce
Partial fix for r88772: no need for IGNORE on site_stats, just interwiki
2011-08-04 23:14:17 +00:00
Sam Reed
66e01d1bb7
Adding __METHOD__ to parameters passed to wfMkdirParents()
2011-07-25 22:01:19 +00:00
Chad Horohoe
d80b53f982
self rv r90483. Still needs investigating though
2011-07-21 22:04:55 +00:00
Alexandre Emsenhuber
f82b49e02b
Pass the Title object to Parser::transformMsg()
2011-06-29 10:58:54 +00:00
Chad Horohoe
d12cc8a163
Mark test incomplete for a legitimate reason like trying to serialize a PDO object--rather than imaginary ones such as blaming memory_limit being too low when the test was being stupid and lowering it for us.
2011-06-20 20:24:53 +00:00
Platonides
efbd16e825
Copy teardownUploadDir(),deleteFiles(),deleteDirs() from parserTest.inc Move down teardownGlobals()
...
This almost fixes the issue of hundreds of leaking mwParser-*-images files at temp dir.
For some unknown reason, there's still one instance left, though.
PS: I thought I had committed this time ago...
2011-06-16 21:07:37 +00:00
Chad Horohoe
c954cb7a4c
* Remove @static from the last few places it's left in core. Please don't use this silly annotation anymore, that's what the static keyword is for.
...
* Enforce protected on SpecialAllPages::getNamespaceKeyAndText(), it's not @private like the comment implies
* Drop User::getMaxID(), nothing uses it
2011-06-14 01:56:55 +00:00
Happy-melon
295f513e8b
More unpicking of r85288. I think this is all of the magic method calls, but they're very hard to grep for (part of the problem with them!), so let's leave the calls in with a wfDeprecated() for a while...
2011-06-03 11:04:49 +00:00
Chad Horohoe
db833df9dc
Remove useless bootstrap inclusions
2011-06-03 04:25:21 +00:00
Antoine Musso
dacec03bde
really add NewParserTest to the Stub group
...
PHPUnit 5.3.13 does not like having comments after the '@group name' command.
This class was not part of the Stub group and run despite the exclusion of
the Stub group in our suite.xml
Properly fix issue described in r89223 and complete r89226
2011-05-31 20:35:35 +00:00
Platonides
6c2654b7f8
Revert r89223. MediaWikiParserTest is needed to run all the $wgParserTestFiles
...
NewParserTest.php standalone running of the first $wgParserTestFiles item is just a convenience.
2011-05-31 20:30:12 +00:00
Antoine Musso
d24a26e713
NewParserTest.php can now work independently
...
PHPUnit load class according to their order on the filesystem I guess.
On the cruisecontrol host, it first load NewParserTest.php and run
the test then load MediaWikiParserTest.php which run the tests too!
On my host the order is reversed, and NewParserTest.php is never run
for a reason I have not investigated.
Anyway, deleting the MediaWikiParserTest.php is harmless since it is
redundant with NewParserTest.php
(should fix cruise control)
2011-05-31 19:51:48 +00:00
Chad Horohoe
b7bc5a8db5
Workaround for duplicate key errors
2011-05-25 00:49:51 +00:00
Chad Horohoe
26ec01f63c
Extend MediaWikiTestCase in a few places
2011-05-25 00:30:06 +00:00
Happy-melon
8ff0177e98
Follow-up r85403: rm unwanted "new" declaration.
2011-05-23 18:57:30 +00:00
Alexandre Emsenhuber
236e3fd6c6
Follow-up r88653: removed the remaining of OutputPage's stubbing
2011-05-23 17:53:31 +00:00
Siebrand Mazeland
75c6696aa8
Use consistent notation for "@todo FIXME". Should update http://svn.wikimedia.org/doc/todo.html nicely.
2011-05-17 22:03:20 +00:00
Platonides
e849a1f153
Tag names can't contain template parameters (thanksfully)
2011-05-04 14:40:25 +00:00
Platonides
cbceed01fa
Follow up r87220. r86795 tests are now embedded into PreprocessorTest.php
2011-05-03 19:53:13 +00:00
Platonides
c6a8d96092
We can't check if it's a parentNode->type == name_node so early, since
...
it may be just a single } and end up being a literal.
2011-05-03 19:48:50 +00:00
Platonides
e5a26f3460
Convert r86795 tests into a dataProvider
2011-05-01 21:33:16 +00:00
Happy-melon
21813a563c
Follow-up r86775: restub $wgLang. Not because it's a good idea, but because I can't see how to avoid the circular dependencies on it *without* stubbing it. Probably easier to just continue the drive to deprecate the global variable altogether.
2011-04-24 10:50:51 +00:00
Mark A. Hershberger
2e6a9b9cea
* Add preprocessor tests that Bergi supplied for Bug #28642
...
* Add Bergi to CREDITS
2011-04-23 21:26:04 +00:00
Mark A. Hershberger
7d90f16834
Use assertStringEqualsFile in place of assertEquals and reading the file.
2011-04-23 21:21:02 +00:00
Mark A. Hershberger
e8ccedbbf0
missed some w/s
2011-04-23 21:18:50 +00:00
Mark A. Hershberger
6c3d0e056e
w/s cleanup
2011-04-23 21:18:22 +00:00
Happy-melon
c80535ae10
Stop stubbing $wgLang and $wgContLang. There are no major code paths which do not call either $wgLang or $wgContLang at least once. All index.php calls unstub $wgContLang from MediaWiki::parseTitle() except in the edgecase of viewing pages referenced only by "curid=123", and since those will end up calling OutputPage::output() they will eventually be unstubbed at some point as well. All calls through load.php unstub $wgLang in ResourceLoaderContext::getLanguage() from ResouceLoader::respond() --> ResourceLoader::preloadModuleInfo(). All calls through api.php unstub $wgContLang in ApiResult::cleanUpUTF8() from ApiMain::printResult().
2011-04-23 15:19:38 +00:00
Platonides
9f63d96785
Change tests to match preprocessor changes in r86072.
...
sed -i 's/<root><\(template\|tplarg\)>/<root><\1 lineStart=\\"1\\">/' phpunit/includes/parser/PreprocessorTest.php
sed -i 's/<root><\(template\|tplarg\)>/<root><\1 lineStart="1">/' parser/preprocess/*.expected
2011-04-19 18:39:37 +00:00
Sam Reed
0bf458ec62
Apply phase3 related Title fixes. With one minor addition, Title constructor marked as protected, "just in case"...
...
Patches by Yuvi Panda
From (bug 28583) Remove all /* private */ declarations in MediaWiki core
2011-04-18 23:20:21 +00:00
Platonides
c878cd608f
r85553 fixup. When there are variants involved, the line
...
$GLOBALS['wgContLang'] = $context->lang;
is not assigning $wgContLang the same $langObj instantiated a couple of lines above, but a different object obtained from the user code, breaking variant parsertestsw..
2011-04-06 21:36:07 +00:00
Happy-melon
f121f89674
Follow-up r85403: fix fatal in parser tests.
2011-04-06 17:39:18 +00:00
Happy-melon
625695317e
Follow-up r85302: update OutputPage constructors in core.
2011-04-05 00:06:47 +00:00
Platonides
25a338f5e0
Add a couple of brace test cases.
2011-03-30 17:41:58 +00:00