Index: trunk/phase3/maintenance/parserTests.inc |
— | — | @@ -640,6 +640,7 @@ |
641 | 641 | 'wgNoFollowLinks' => true, |
642 | 642 | 'wgNoFollowDomainExceptions' => array(), |
643 | 643 | 'wgThumbnailScriptPath' => false, |
| 644 | + 'wgUseImageResize' => false, |
644 | 645 | 'wgUseTeX' => false, |
645 | 646 | 'wgLocaltimezone' => 'UTC', |
646 | 647 | 'wgAllowExternalImages' => true, |
Index: trunk/phase3/maintenance/parserTests.txt |
— | — | @@ -3283,7 +3283,7 @@ |
3284 | 3284 | !! input |
3285 | 3285 | [[Image:foobar.jpg|thumb|http://example.com]] |
3286 | 3286 | !! result |
3287 | | -<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a href="http://example.com" class="external free" rel="nofollow">http://example.com</a></div></div></div> |
| 3287 | +<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/3/3a/Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a href="http://example.com" class="external free" rel="nofollow">http://example.com</a></div></div></div> |
3288 | 3288 | |
3289 | 3289 | !! end |
3290 | 3290 | |
— | — | @@ -3292,7 +3292,7 @@ |
3293 | 3293 | !! input |
3294 | 3294 | [[Image:foobar.jpg|thumb|http://example.com|alt=Alteration]] |
3295 | 3295 | !! result |
3296 | | -<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="Alteration" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a href="http://example.com" class="external free" rel="nofollow">http://example.com</a></div></div></div> |
| 3296 | +<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="Alteration" src="http://example.com/images/3/3a/Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a href="http://example.com" class="external free" rel="nofollow">http://example.com</a></div></div></div> |
3297 | 3297 | |
3298 | 3298 | !! end |
3299 | 3299 | |
— | — | @@ -3301,7 +3301,7 @@ |
3302 | 3302 | !! input |
3303 | 3303 | [[Image:foobar.jpg|thumb|ISBN 1235467890]] |
3304 | 3304 | !! result |
3305 | | -<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a href="https://www.mediawiki.org/wiki/Special:BookSources/1235467890" class="internal mw-magiclink-isbn">ISBN 1235467890</a></div></div></div> |
| 3305 | +<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/3/3a/Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a href="https://www.mediawiki.org/wiki/Special:BookSources/1235467890" class="internal mw-magiclink-isbn">ISBN 1235467890</a></div></div></div> |
3306 | 3306 | |
3307 | 3307 | !! end |
3308 | 3308 | |
— | — | @@ -3310,7 +3310,7 @@ |
3311 | 3311 | !! input |
3312 | 3312 | [[Image:foobar.jpg|thumb|This is RFC 12354]] |
3313 | 3313 | !! result |
3314 | | -<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This is <a href="http://tools.ietf.org/html/rfc12354" class="external mw-magiclink-rfc">RFC 12354</a></div></div></div> |
| 3314 | +<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/3/3a/Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This is <a href="http://tools.ietf.org/html/rfc12354" class="external mw-magiclink-rfc">RFC 12354</a></div></div></div> |
3315 | 3315 | |
3316 | 3316 | !! end |
3317 | 3317 | |
— | — | @@ -3319,7 +3319,7 @@ |
3320 | 3320 | !! input |
3321 | 3321 | [[Image:foobar.jpg|thumb|Please mailto:nobody@example.com]] |
3322 | 3322 | !! result |
3323 | | -<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Please <a href="mailto:nobody@example.com" class="external free" rel="nofollow">mailto:nobody@example.com</a></div></div></div> |
| 3323 | +<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/3/3a/Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Please <a href="mailto:nobody@example.com" class="external free" rel="nofollow">mailto:nobody@example.com</a></div></div></div> |
3324 | 3324 | |
3325 | 3325 | !! end |
3326 | 3326 | |
— | — | @@ -3329,7 +3329,7 @@ |
3330 | 3330 | !! input |
3331 | 3331 | [[Image:foobar.jpg|thumb|<math>2+2</math>]] |
3332 | 3332 | !! result |
3333 | | -<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><math>2+2</math></div></div></div> |
| 3333 | +<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/3/3a/Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><math>2+2</math></div></div></div> |
3334 | 3334 | |
3335 | 3335 | !! end |
3336 | 3336 | |
— | — | @@ -3340,7 +3340,7 @@ |
3341 | 3341 | !! input |
3342 | 3342 | [[Image:foobar.jpg|thumb|<math>2+2</math>]] |
3343 | 3343 | !! result |
3344 | | -<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><span class="texhtml">2 + 2</span></div></div></div> |
| 3344 | +<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/3/3a/Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><span class="texhtml">2 + 2</span></div></div></div> |
3345 | 3345 | |
3346 | 3346 | !! end |
3347 | 3347 | |
— | — | @@ -3413,7 +3413,7 @@ |
3414 | 3414 | !! input |
3415 | 3415 | [[Image:Foobar.jpg|thumb|This is a caption with another [[Image:icon.png|image]] inside it!]] |
3416 | 3416 | !! result |
3417 | | -<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This is a caption with another <a href="https://www.mediawiki.org/index.php?title=Special:Upload&wpDestFile=Icon.png" class="new" title="File:Icon.png">File:Icon.png</a> inside it!</div></div></div> |
| 3417 | +<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/3/3a/Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This is a caption with another <a href="https://www.mediawiki.org/index.php?title=Special:Upload&wpDestFile=Icon.png" class="new" title="File:Icon.png">File:Icon.png</a> inside it!</div></div></div> |
3418 | 3418 | |
3419 | 3419 | !! end |
3420 | 3420 | |
— | — | @@ -3433,7 +3433,7 @@ |
3434 | 3434 | !! input |
3435 | 3435 | [[Image:Foobar.jpg|thumb|200px|This caption has [irc://example.net irc] and [https://example.com Secure] ext links in it.]] |
3436 | 3436 | !! result |
3437 | | -<div class="thumb tright"><div class="thumbinner" style="width:202px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" width="200" height="23" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This caption has <a href="irc://example.net" class="external text" rel="nofollow">irc</a> and <a href="https://example.com" class="external text" rel="nofollow">Secure</a> ext links in it.</div></div></div> |
| 3437 | +<div class="thumb tright"><div class="thumbinner" style="width:202px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/3/3a/Foobar.jpg" width="200" height="23" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This caption has <a href="irc://example.net" class="external text" rel="nofollow">irc</a> and <a href="https://example.com" class="external text" rel="nofollow">Secure</a> ext links in it.</div></div></div> |
3438 | 3438 | |
3439 | 3439 | !! end |
3440 | 3440 | |
— | — | @@ -6381,7 +6381,7 @@ |
6382 | 6382 | !! input |
6383 | 6383 | [[Image:foobar.jpg|640x480px]] |
6384 | 6384 | !! result |
6385 | | -<p><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/640px-Foobar.jpg" width="640" height="73" /></a> |
| 6385 | +<p><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="640" height="73" /></a> |
6386 | 6386 | </p> |
6387 | 6387 | !!end |
6388 | 6388 | |
— | — | @@ -6390,7 +6390,7 @@ |
6391 | 6391 | !! input |
6392 | 6392 | [[Image:foobar.jpg|640px]] |
6393 | 6393 | !! result |
6394 | | -<p><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/640px-Foobar.jpg" width="640" height="73" /></a> |
| 6394 | +<p><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="640" height="73" /></a> |
6395 | 6395 | </p> |
6396 | 6396 | !!end |
6397 | 6397 | |
— | — | @@ -6399,7 +6399,7 @@ |
6400 | 6400 | !! input |
6401 | 6401 | [[Image:foobar.jpg|640px ]] |
6402 | 6402 | !! result |
6403 | | -<p><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/640px-Foobar.jpg" width="640" height="73" /></a> |
| 6403 | +<p><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="640" height="73" /></a> |
6404 | 6404 | </p> |
6405 | 6405 | !!end |
6406 | 6406 | |
— | — | @@ -6408,7 +6408,7 @@ |
6409 | 6409 | !! input |
6410 | 6410 | [[Image:foobar.jpg| 640px]] |
6411 | 6411 | !! result |
6412 | | -<p><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/640px-Foobar.jpg" width="640" height="73" /></a> |
| 6412 | +<p><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="640" height="73" /></a> |
6413 | 6413 | </p> |
6414 | 6414 | !!end |
6415 | 6415 | |
— | — | @@ -6450,7 +6450,7 @@ |
6451 | 6451 | !! input |
6452 | 6452 | [[image:Foobar.jpg|thumb|An [http://test/?param1=|left|¶m2=|x external] URL]] |
6453 | 6453 | !! result |
6454 | | -<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="An external URL" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>An <a href="http://test/?param1=|left|&param2=|x" class="external text" rel="nofollow">external</a> URL</div></div></div> |
| 6454 | +<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="An external URL" src="http://example.com/images/3/3a/Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>An <a href="http://test/?param1=|left|&param2=|x" class="external text" rel="nofollow">external</a> URL</div></div></div> |
6455 | 6455 | |
6456 | 6456 | !!end |
6457 | 6457 | |
— | — | @@ -7351,7 +7351,7 @@ |
7352 | 7352 | !! input |
7353 | 7353 | [[Image:Foobar.jpg|thumb|http://x|hello]] |
7354 | 7354 | !! result |
7355 | | -<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>hello</div></div></div> |
| 7355 | +<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/3/3a/Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>hello</div></div></div> |
7356 | 7356 | |
7357 | 7357 | !! end |
7358 | 7358 | |
Index: trunk/phase3/tests/MediaWiki_TestCase.php |
— | — | @@ -7,7 +7,10 @@ |
8 | 8 | */ |
9 | 9 | protected function buildTestDatabase( $tables ) { |
10 | 10 | global $testOptions, $wgDBprefix, $wgDBserver, $wgDBadminuser, $wgDBadminpassword, $wgDBname; |
11 | | - $this->markTestIncomplete("This test requires DB admin user credentials."); |
| 11 | + if(!$wgDBadminuser || !$wgDBadminpassword) { |
| 12 | + $this->markTestIncomplete("This test requires DB admin user credentials."); |
| 13 | + } |
| 14 | + |
12 | 15 | $wgDBprefix = 'parsertest_'; |
13 | 16 | |
14 | 17 | $db = new DatabaseMysql( |
— | — | @@ -16,7 +19,8 @@ |
17 | 20 | $wgDBadminpassword, |
18 | 21 | $wgDBname ); |
19 | 22 | if( $db->isOpen() ) { |
20 | | - if (!(strcmp($db->getServerVersion(), '4.1') < 0 and stristr($db->getSoftwareLink(), 'MySQL'))) { |
| 23 | + if (!(strcmp($db->getServerVersion(), '4.1') < 0 and |
| 24 | + stristr($db->getSoftwareLink(), 'MySQL'))) { |
21 | 25 | # Database that supports CREATE TABLE ... LIKE |
22 | 26 | foreach ($tables as $tbl) { |
23 | 27 | $newTableName = $db->tableName( $tbl ); |
— | — | @@ -41,7 +45,6 @@ |
42 | 46 | } |
43 | 47 | $db->query($create_tmp); |
44 | 48 | } |
45 | | - |
46 | 49 | } |
47 | 50 | return $db; |
48 | 51 | } else { |
Index: trunk/phase3/tests/MediaWikiParserTest.php |
— | — | @@ -23,7 +23,6 @@ |
24 | 24 | |
25 | 25 | function showSuccess( $desc ) { |
26 | 26 | $this->cb->assertTrue( true, $desc ); |
27 | | - echo "PASSED: $desc\n"; |
28 | 27 | return true; |
29 | 28 | } |
30 | 29 | |
— | — | @@ -146,21 +145,10 @@ |
147 | 146 | $wgStyleSheetPath = '/skins'; |
148 | 147 | $wgStylePath = '/skins'; |
149 | 148 | $wgThumbnailScriptPath = false; |
150 | | - $this->uploadDir = $this->setupUploadDir(); |
151 | | - $wgLocalFileRepo = array( |
152 | | - 'class' => 'LocalRepo', |
153 | | - 'name' => 'local', |
154 | | - 'directory' => $this->uploadDir, |
155 | | - 'url' => 'http://example.com/images', |
156 | | - 'hashLevels' => 2, |
157 | | - 'transformVia404' => false, |
158 | | - ); |
159 | | - //$wgNamespacesWithSubpages = array( 0 => isset( $opts['subpage'] ) ); |
160 | 149 | $wgNamespaceProtection[NS_MEDIAWIKI] = 'editinterface'; |
161 | 150 | $wgNamespaceAliases['Image'] = NS_FILE; |
162 | 151 | $wgNamespaceAliases['Image_talk'] = NS_FILE_TALK; |
163 | 152 | |
164 | | - |
165 | 153 | $wgEnableParserCache = false; |
166 | 154 | $wgDeferredUpdateList = array(); |
167 | 155 | $wgMemc =& wfGetMainCache(); |
— | — | @@ -181,35 +169,8 @@ |
182 | 170 | $this->parserTester = new PTShell(); |
183 | 171 | $this->parserTester->setCallback( $this ); |
184 | 172 | |
185 | | - /* global $wgDBtype, $wgDBserver, $wgDBname, $wgDBuser, $wgDBpassword, $wgDBport, $wgDBmwschema, $wgDBts2chema; */ |
186 | | - /* $this->db['type'] = $wgDBtype; */ |
187 | | - /* $this->db['server'] = $wgDBserver; */ |
188 | | - /* $this->db['name'] = $wgDBname; */ |
189 | | - /* $this->db['user'] = $wgDBuser; */ |
190 | | - /* $this->db['password'] = $wgDBpassword; */ |
191 | | - /* $this->db['port'] = $wgDBport; */ |
192 | | - /* $this->db['mwschema'] = $wgDBmwschema; */ |
193 | | - /* $this->db['ts2schema'] = $wgDBts2chema; */ |
194 | 173 | } |
195 | 174 | |
196 | | - function tearDown() { |
197 | | - $this->teardownUploadDir($this->uploadDir); |
198 | | - /* $db = wfGetDB( DB_MASTER ); */ |
199 | | - /* $db->close(); */ |
200 | | - /* global $wgDBtype, $wgDBserver, $wgDBname, $wgDBuser, $wgDBpassword, $wgDBport, $wgDBmwschema, $wgDBts2chema; */ |
201 | | - |
202 | | - /* $wgDBtype = $this->db['type']; */ |
203 | | - /* $wgDBserver = $this->db['server']; */ |
204 | | - /* $wgDBname = $this->db['name']; */ |
205 | | - /* $wgDBuser = $this->db['user']; */ |
206 | | - /* $wgDBpassword = $this->db['password']; */ |
207 | | - /* $wgDBport = $this->db['port']; */ |
208 | | - /* $wgDBmwschema = $this->db['mwschema']; */ |
209 | | - /* $wgDBts2chema = $this->db['ts2schema']; */ |
210 | | - |
211 | | - } |
212 | | - |
213 | | - |
214 | 175 | function testParser() { |
215 | 176 | global $IP; |
216 | 177 | |
Index: trunk/phase3/includes/MessageCache.php |
— | — | @@ -399,16 +399,18 @@ |
400 | 400 | |
401 | 401 | // Also delete cached sidebar... just in case it is affected |
402 | 402 | global $parserMemc; |
403 | | - $codes = array( $code ); |
404 | | - if ( $code === 'en' ) { |
405 | | - // Delete all sidebars, like for example on action=purge on the |
406 | | - // sidebar messages |
407 | | - $codes = array_keys( Language::getLanguageNames() ); |
408 | | - } |
| 403 | + if(is_object($parserMemc)) { |
| 404 | + $codes = array( $code ); |
| 405 | + if ( $code === 'en' ) { |
| 406 | + // Delete all sidebars, like for example on action=purge on the |
| 407 | + // sidebar messages |
| 408 | + $codes = array_keys( Language::getLanguageNames() ); |
| 409 | + } |
409 | 410 | |
410 | | - foreach ( $codes as $code ) { |
411 | | - $sidebarKey = wfMemcKey( 'sidebar', $code ); |
412 | | - $parserMemc->delete( $sidebarKey ); |
| 411 | + foreach ( $codes as $code ) { |
| 412 | + $sidebarKey = wfMemcKey( 'sidebar', $code ); |
| 413 | + $parserMemc->delete( $sidebarKey ); |
| 414 | + } |
413 | 415 | } |
414 | 416 | |
415 | 417 | wfRunHooks( "MessageCacheReplace", array( $title, $text ) ); |
Index: trunk/phase3/includes/Title.php |
— | — | @@ -3451,7 +3451,12 @@ |
3452 | 3452 | * @return \type{\string} String representation of this title |
3453 | 3453 | */ |
3454 | 3454 | public function __toString() { |
3455 | | - return $this->getPrefixedText(); |
| 3455 | + $bt = debug_backtrace(); |
| 3456 | + foreach($bt as $b) { |
| 3457 | + print "{$b['file']}:{$b['line']}\n"; |
| 3458 | + } |
| 3459 | + exit; |
| 3460 | + return $this->getPrefixedText(); |
3456 | 3461 | } |
3457 | 3462 | |
3458 | 3463 | /** |
Index: trunk/phase3/includes/Namespace.php |
— | — | @@ -8,6 +8,7 @@ |
9 | 9 | * Definitions of the NS_ constants are in Defines.php |
10 | 10 | * @private |
11 | 11 | */ |
| 12 | +global $wgCanonicalNamespaceNames; |
12 | 13 | $wgCanonicalNamespaceNames = array( |
13 | 14 | NS_MEDIA => 'Media', |
14 | 15 | NS_SPECIAL => 'Special', |