MediaWiki  REL1_24
SpecialJavaScriptTest Class Reference
Inheritance diagram for SpecialJavaScriptTest:
Collaboration diagram for SpecialJavaScriptTest:

List of all members.

Public Member Functions

 __construct ()
 execute ($par)
 Default execute method Checks user permissions.
 prefixSearchSubpages ($search, $limit=10)
 Return an array of subpages beginning with $search that this special page will accept.

Protected Member Functions

 getGroupName ()
 Under which header this special page is listed in Special:SpecialPages See messages 'specialpages-group-*' for valid names This method defaults to group 'other'.

Private Member Functions

 getFrameworkListHtml ()
 Get a list of frameworks (including introduction paragraph and links to the framework run pages)
 initQUnitTesting ()
 Initialize the page for QUnit.
 wrapSummaryHtml ($html, $state)
 Function to wrap the summary.

Static Private Attributes

static $frameworks

Detailed Description

Definition at line 27 of file SpecialJavaScriptTest.php.


Constructor & Destructor Documentation


Member Function Documentation

Default execute method Checks user permissions.

This must be overridden by subclasses; it will be made abstract in a future version

Parameters:
string | null$subPage

Reimplemented from SpecialPage.

Definition at line 41 of file SpecialJavaScriptTest.php.

References $out, $summary, getFrameworkListHtml(), SpecialPage\getOutput(), SpecialPage\getPageTitle(), Linker\linkKnown(), SpecialPage\msg(), SpecialPage\setHeaders(), and wrapSummaryHtml().

Get a list of frameworks (including introduction paragraph and links to the framework run pages)

Returns:
string HTML

Definition at line 92 of file SpecialJavaScriptTest.php.

References array(), as, SpecialPage\getPageTitle(), Linker\link(), SpecialPage\msg(), and Html\rawElement().

Referenced by execute().

Under which header this special page is listed in Special:SpecialPages See messages 'specialpages-group-*' for valid names This method defaults to group 'other'.

Returns:
string
Since:
1.21

Reimplemented from SpecialPage.

Definition at line 190 of file SpecialJavaScriptTest.php.

SpecialJavaScriptTest::prefixSearchSubpages ( search,
limit = 10 
)

Return an array of subpages beginning with $search that this special page will accept.

Parameters:
string$searchPrefix to search for
int$limitMaximum number of results to return
Returns:
string[] Matching subpages

Reimplemented from SpecialPage.

Definition at line 182 of file SpecialJavaScriptTest.php.

References $limit, and SpecialPage\prefixSearchArray().

SpecialJavaScriptTest::wrapSummaryHtml ( html,
state 
) [private]

Function to wrap the summary.

It must be given a valid state as a second parameter or an exception will be thrown.

Parameters:
string$htmlThe raw HTML.
string$stateState, one of 'noframework', 'unknownframework' or 'frameworkfound'
Exceptions:
MWException
Returns:
string

Definition at line 120 of file SpecialJavaScriptTest.php.

References array().

Referenced by execute(), and initQUnitTesting().


Member Data Documentation

SpecialJavaScriptTest::$frameworks [static, private]
Initial value:
 array(
        'qunit' => 'initQUnitTesting',
    )

Definition at line 33 of file SpecialJavaScriptTest.php.


The documentation for this class was generated from the following file: