aboutsummaryrefslogtreecommitdiffstats
path: root/tests/parser
diff options
context:
space:
mode:
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>2014-06-27 14:04:26 +0000
committerGerrit Code Review <gerrit@wikimedia.org>2014-06-27 14:04:26 +0000
commite9df496d1171ff7bccc35c36839a5328838b83ca (patch)
treea170a8b6dfff8b289f0b1449e85338687a019373 /tests/parser
parent572f73740aec887a264c8327044947433b4631fa (diff)
parent09498e1d7fecb272d49085c553ad19be3e4958b6 (diff)
downloadmediawikicore-e9df496d1171ff7bccc35c36839a5328838b83ca.tar.gz
mediawikicore-e9df496d1171ff7bccc35c36839a5328838b83ca.zip
Merge "Add parser test for "extra interlanguage links"."
Diffstat (limited to 'tests/parser')
-rw-r--r--tests/parser/parserTest.inc9
-rw-r--r--tests/parser/parserTests.txt10
2 files changed, 19 insertions, 0 deletions
diff --git a/tests/parser/parserTest.inc b/tests/parser/parserTest.inc
index 5d521608a76b..6c8a4012c255 100644
--- a/tests/parser/parserTest.inc
+++ b/tests/parser/parserTest.inc
@@ -153,6 +153,7 @@ class ParserTest {
global $wgParser, $wgParserConf, $IP, $messageMemc, $wgMemc,
$wgUser, $wgLang, $wgOut, $wgRequest, $wgStyleDirectory, $wgEnableParserCache,
$wgExtraNamespaces, $wgNamespaceAliases, $wgNamespaceProtection, $wgLocalFileRepo,
+ $wgExtraInterlanguageLinkPrefixes,
$parserMemc, $wgThumbnailScriptPath, $wgScriptPath,
$wgArticlePath, $wgScript, $wgStylePath, $wgExtensionAssetsPath,
$wgMainCacheType, $wgMessageCacheType, $wgParserCacheType, $wgLockManagers;
@@ -223,6 +224,9 @@ class ParserTest {
if ( $wgStyleDirectory === false ) {
$wgStyleDirectory = "$IP/skins";
}
+ // "extra language links"
+ // see https://gerrit.wikimedia.org/r/111390
+ array_push( $wgExtraInterlanguageLinkPrefixes, 'mul' );
self::setupInterwikis();
}
@@ -276,6 +280,11 @@ class ParserTest {
'iw_api' => '',
'iw_wikiid' => '',
'iw_local' => 1 ),
+ 'mul' => array(
+ 'iw_url' => 'http://wikisource.org/wiki/$1',
+ 'iw_api' => '',
+ 'iw_wikiid' => '',
+ 'iw_local' => 1 ),
);
if ( array_key_exists( $prefix, $testInterwikis ) ) {
$iwData = $testInterwikis[$prefix];
diff --git a/tests/parser/parserTests.txt b/tests/parser/parserTests.txt
index f6238bb804ed..e4d93242e4b1 100644
--- a/tests/parser/parserTests.txt
+++ b/tests/parser/parserTests.txt
@@ -6408,6 +6408,16 @@ Blah blah blah
!! end
!! test
+"Extra" interlanguage links (bug 32189 / gerrit 111390)
+!! wikitext
+Blah blah blah
+[[mul:Multilingual]]
+!! html
+<p>Blah blah blah
+</p>
+!! end
+
+!! test
Parsoid-specific test: Wikilinks with &nbsp; should RT properly
!! options
language=ln