* Initialize the page for QUnit.
*/
private function initQUnitTesting() {
- global $wgJavaScriptTestConfig;
-
$out = $this->getOutput();
$out->addModules( 'test.mediawiki.qunit.testrunner' );
$out->addModules( $qunitTestModules );
$summary = $this->msg( 'javascripttest-qunit-intro' )
- ->params( $wgJavaScriptTestConfig['qunit']['documentation'] )
+ ->params( 'https://www.mediawiki.org/wiki/Manual:JavaScript_unit_testing' )
->parseAsBlock();
$header = $this->msg( 'javascripttest-qunit-heading' )->escaped();
$userDir = $this->getLanguage()->getDir();
$out->addHtml( $this->wrapSummaryHtml( $summary, 'frameworkfound' ) . $baseHtml );
// This special page is disabled by default ($wgEnableJavaScriptTest), and contains
- // no sensitive data. In order to allow TestSwarm to embed it into a test client window,
+ // no sensitive data. In order to allow test frameworks to embed it into a test client window,
// we need to allow iframing of this page.
$out->allowClickjacking();
-
- // Used in ./tests/qunit/data/testrunner.js, see also documentation of
- // $wgJavaScriptTestConfig in DefaultSettings.php
- $out->addJsConfigVars(
- 'QUnitTestSwarmInjectJSPath',
- $wgJavaScriptTestConfig['qunit']['testswarm-injectjs']
- );
}
/**
- * Return an array of subpages beginning with $search that this special page will accept.
+ * Return an array of subpages that this special page will accept.
*
- * @param string $search Prefix to search for
- * @param integer $limit Maximum number of results to return
- * @return string[] Matching subpages
+ * @return string[] subpages
*/
- public function prefixSearchSubpages( $search, $limit = 10 ) {
- return self::prefixSearchArray(
- $search,
- $limit,
- array_keys( self::$frameworks )
- );
+ public function getSubpagesForPrefixSearch() {
+ return array_keys( self::$frameworks );
}
protected function getGroupName() {