MediaWiki  REL1_21
TitleTest Class Reference

Database ^--- needed for language cache stuff More...

Inheritance diagram for TitleTest:
Collaboration diagram for TitleTest:

List of all members.

Public Member Functions

 dataTestIsValidMoveOperation ()
 Provides test parameter values for testIsValidMoveOperation()
 dataWgWhitelistReadRegexp ()
 Provides test parameter values for testWgWhitelistReadRegexp()
 flattenErrorsArray ($errors)
 provideBaseTitleCases ()
 provideCasesForGetpageviewlanguage ()
 provideSubpageTitleCases ()
 testBug31100FixSpecialName ($text, $expectedParam)
 provideBug31100
 testExtractingBaseTextFromTitle ($title, $expected, $msg= '')
 provideBaseTitleCases
 testExtractingRootTextFromTitle ($title, $expected, $msg= '')
 provideRootTitleCases
 testExtractingSubpageTextFromTitle ($title, $expected, $msg= '')
 testGetpageviewlanguage ($expected, $titleText, $contLang, $lang, $variant, $msg= '')
 provideCasesForGetpageviewlanguage
 testIsValidMoveOperation ($source, $target, $expected)
 Auth-less test of Title::isValidMoveOperation.
 testLegalChars ()
 testWgWhitelistReadRegexp ($whitelistRegexp, $source, $action, $expected)
 Auth-less test of Title::userCan.

Static Public Member Functions

static provideBug31100 ()
static provideRootTitleCases ()
static provideTestIsValidMoveOperation ()

Protected Member Functions

 setUp ()
 setUp and tearDown should (where significant) happen in reverse order.

Detailed Description

Database ^--- needed for language cache stuff

Definition at line 8 of file TitleTest.php.


Member Function Documentation

Provides test parameter values for testIsValidMoveOperation()

Definition at line 84 of file TitleTest.php.

References array().

Provides test parameter values for testWgWhitelistReadRegexp()

Definition at line 159 of file TitleTest.php.

References array().

Definition at line 195 of file TitleTest.php.

References $error, $result, array(), and as.

Referenced by testIsValidMoveOperation(), and testWgWhitelistReadRegexp().

Definition at line 283 of file TitleTest.php.

References array(), and message.

static TitleTest::provideBug31100 ( ) [static]

Definition at line 50 of file TitleTest.php.

References array().

Definition at line 233 of file TitleTest.php.

References array().

static TitleTest::provideRootTitleCases ( ) [static]

Definition at line 302 of file TitleTest.php.

References array(), and message.

Definition at line 322 of file TitleTest.php.

References array(), and message.

Definition at line 203 of file TitleTest.php.

References array().

TitleTest::setUp ( ) [protected]

setUp and tearDown should (where significant) happen in reverse order.

Reimplemented from MediaWikiTestCase.

Definition at line 9 of file TitleTest.php.

References array(), Language\factory(), and MediaWikiTestCase\setMwGlobals().

TitleTest::testBug31100FixSpecialName ( text,
expectedParam 
)

provideBug31100

Definition at line 38 of file TitleTest.php.

References $title, and Title\newFromText().

TitleTest::testExtractingBaseTextFromTitle ( title,
expected,
msg = '' 
)

provideBaseTitleCases

Definition at line 275 of file TitleTest.php.

References $title, and Title\newFromText().

TitleTest::testExtractingRootTextFromTitle ( title,
expected,
msg = '' 
)

provideRootTitleCases

Definition at line 294 of file TitleTest.php.

References $title, and Title\newFromText().

TitleTest::testExtractingSubpageTextFromTitle ( title,
expected,
msg = '' 
)
Todo:
Handle $wgNamespacesWithSubpages cases provideSubpageTitleCases

Definition at line 314 of file TitleTest.php.

References $title, and Title\newFromText().

TitleTest::testGetpageviewlanguage ( expected,
titleText,
contLang,
lang,
variant,
msg = '' 
)

provideCasesForGetpageviewlanguage

Definition at line 213 of file TitleTest.php.

References $title, $wgContLang, $wgLang, Language\factory(), global, and Title\newFromText().

TitleTest::testIsValidMoveOperation ( source,
target,
expected 
)

Auth-less test of Title::isValidMoveOperation.

Database

Parameters:
string$source
string$target
array | string | true$expectedRequired error provideTestIsValidMoveOperation

Definition at line 67 of file TitleTest.php.

References $error, $source, $title, array(), as, flattenErrorsArray(), and Title\newFromText().

Definition at line 22 of file TitleTest.php.

References as, and Title\legalChars().

TitleTest::testWgWhitelistReadRegexp ( whitelistRegexp,
source,
action,
expected 
)

Auth-less test of Title::userCan.

Parameters:
array$whitelistRegexp
string$source
string$action
array | string | true$expectedRequired error

Title::checkReadPermissions dataWgWhitelistReadRegexp

Definition at line 102 of file TitleTest.php.

References $error, $source, $title, $wgUser, array(), as, flattenErrorsArray(), global, and Title\newFromDBkey().


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