Index: trunk/phase3/resources/mediawiki/mediawiki.utiltest.js |
— | — | @@ -1,5 +1,6 @@ |
2 | 2 | /* |
3 | | - * mediaWiki Debug Test Suit on [[Special:MWUtilJSTest]] (only when ?debug=true) |
| 3 | + * mediaWiki Debug Test Suit. |
| 4 | + * Available on "/Special:BlankPage?action=mwutiltest&debug=true") |
4 | 5 | */ |
5 | 6 | |
6 | 7 | (function ($, mw) { |
— | — | @@ -30,7 +31,7 @@ |
31 | 32 | if (this.initialised === false) { |
32 | 33 | this.initialised = true; |
33 | 34 | $(function () { |
34 | | - if (wgTitle == 'MWUtilJSTest' && wgCanonicalNamespace == 'Special') { |
| 35 | + if (wgCanonicalSpecialPageName == 'Blankpage' && mw.util.getParamValue('action') === 'mwutiltest') { |
35 | 36 | |
36 | 37 | // Build page |
37 | 38 | document.title = 'mediaWiki.util JavaScript Test - ' + wgSiteName; |
— | — | @@ -76,8 +77,8 @@ |
77 | 78 | 'function (string)'); |
78 | 79 | mw.test.addTest('typeof mw.util.getParamValue', |
79 | 80 | 'function (string)'); |
80 | | - mw.test.addTest('mw.util.getParamValue(\'debug\')', |
81 | | - 'true (string)'); |
| 81 | + mw.test.addTest('mw.util.getParamValue(\'action\')', |
| 82 | + 'mwutiltest (string)'); |
82 | 83 | mw.test.addTest('typeof mw.util.htmlEscape', |
83 | 84 | 'function (string)'); |
84 | 85 | mw.test.addTest('mw.util.htmlEscape(\'<a href="http://mw.org/?a=b&c=d">link</a>\')', |