MediaWiki
1.23.2
|
@group Database ^— needed for language cache stuff More...
Public Member Functions | |
dataTestIsValidMoveOperation () | |
Provides test parameter values for testIsValidMoveOperation() More... | |
dataWgWhitelistReadRegexp () | |
Provides test parameter values for testWgWhitelistReadRegexp() More... | |
flattenErrorsArray ( $errors) | |
provideGetFragment () | |
provideGetTitleValue () | |
provideNewFromTitleValue () | |
testBug31100FixSpecialName ( $text, $expectedParam) | |
@dataProvider provideBug31100 @covers Title::fixSpecialName More... | |
testConvertByteClassToUnicodeClass ( $byteClass, $unicodeClass) | |
@dataProvider provideConvertByteClassToUnicodeClass @covers Title::convertByteClassToUnicodeClass More... | |
testGetBaseText ( $title, $expected, $msg='') | |
@dataProvider provideBaseTitleCases @covers Title::getBaseText More... | |
testGetFragment ( $full, $fragment) | |
@dataProvider provideGetFragment More... | |
testGetPageViewLanguage ( $expected, $titleText, $contLang, $lang, $variant, $msg='') | |
@dataProvider provideGetPageViewLanguage @covers Title::getPageViewLanguage More... | |
testGetRootText ( $title, $expected, $msg='') | |
@dataProvider provideRootTitleCases @covers Title::getRootText More... | |
testGetSubpageText ( $title, $expected, $msg='') | |
testGetTitleValue ( $text) | |
@dataProvider provideGetTitleValue More... | |
testIsValidMoveOperation ( $source, $target, $expected) | |
Auth-less test of Title::isValidMoveOperation. More... | |
testLegalChars () | |
@covers Title::legalChars More... | |
testNewFromTitleValue (TitleValue $value) | |
@dataProvider provideNewFromTitleValue More... | |
testSecureAndSplit () | |
See also mediawiki.Title.test.js @covers Title::secureAndSplit. More... | |
testWgWhitelistReadRegexp ( $whitelistRegexp, $source, $action, $expected) | |
Auth-less test of Title::userCan. More... | |
Public Member Functions inherited from MediaWikiTestCase | |
__call ( $func, $args) | |
__construct ( $name=null, array $data=array(), $dataName='') | |
addDBData () | |
Stub. More... | |
dbPrefix () | |
getCliArg ( $offset) | |
hideDeprecated ( $function) | |
Don't throw a warning if $function is deprecated and called later. More... | |
needsDB () | |
run (PHPUnit_Framework_TestResult $result=null) | |
setCliArg ( $offset, $value) | |
testMediaWikiTestCaseParentSetupCalled () | |
Make sure MediaWikiTestCase extending classes have called their parent setUp method. More... | |
usesTemporaryTables () | |
Static Public Member Functions | |
static | provideBaseTitleCases () |
static | provideBug31100 () |
static | provideConvertByteClassToUnicodeClass () |
static | provideGetPageViewLanguage () |
static | provideRootTitleCases () |
static | provideSubpageTitleCases () |
static | provideTestIsValidMoveOperation () |
Static Public Member Functions inherited from MediaWikiTestCase | |
static | listTables ( $db) |
static | setupTestDB (DatabaseBase $db, $prefix) |
Creates an empty skeleton of the wiki database by cloning its structure to equivalent tables using the given $prefix. More... | |
static | teardownTestDB () |
Restores MediaWiki to using the table set (table prefix) it was using before setupTestDB() was called. More... | |
Protected Member Functions | |
setUp () | |
Protected Member Functions inherited from MediaWikiTestCase | |
arrayWrap (array $elements) | |
Utility method taking an array of elements and wrapping each element in it's own array. More... | |
assertArrayEquals (array $expected, array $actual, $ordered=false, $named=false) | |
Assert that two arrays are equal. More... | |
assertException ( $code, $expected='Exception', $message='') | |
Asserts that an exception of the specified type occurs when running the provided code. More... | |
assertHTMLEquals ( $expected, $actual, $msg='') | |
Put each HTML element on its own line and then equals() the results. More... | |
assertSelect ( $table, $fields, $condition, array $expectedRows) | |
Asserts that the given database query yields the rows given by $expectedRows. More... | |
assertType ( $type, $actual, $message='') | |
Asserts the type of the provided value. More... | |
assertTypeOrValue ( $type, $actual, $value=false, $message='') | |
Asserts that the provided variable is of the specified internal type or equals the $value argument. More... | |
assertValidHtmlDocument ( $html) | |
Asserts that the given string is valid HTML document. More... | |
assertValidHtmlSnippet ( $html) | |
Asserts that the given string is a valid HTML snippet. More... | |
checkDbIsSupported () | |
checkHasDiff3 () | |
Check, if $wgDiff3 is set and ready to merge Will mark the calling test as skipped, if not ready. More... | |
checkHasGzip () | |
Check whether we have the 'gzip' commandline utility, will skip the test whenever "gzip -V" fails. More... | |
checkPHPExtension ( $extName) | |
Check if $extName is a loaded PHP extension, will skip the test whenever it is not loaded. More... | |
getDefaultWikitextNS () | |
Returns the ID of a namespace that defaults to Wikitext. More... | |
getNewTempDirectory () | |
obtains a new temporary directory More... | |
getNewTempFile () | |
Obtains a new temporary file name. More... | |
isWikitextNS ( $ns) | |
Returns true if the given namespace defaults to Wikitext according to $wgNamespaceContentModels. More... | |
mergeMwGlobalArrayValue ( $name, $values) | |
Merges the given values into a MW global array variable. More... | |
objectAssociativeSort (array &$array) | |
Does an associative sort that works for objects. More... | |
setMwGlobals ( $pairs, $value=null) | |
stashMwGlobals ( $globalKeys) | |
Stashes the global, will be restored in tearDown() More... | |
tearDown () | |
Additional Inherited Members | |
Public Attributes inherited from MediaWikiTestCase | |
const | DB_PREFIX = 'unittest_' |
Table name prefixes. More... | |
const | ORA_DB_PREFIX = 'ut_' |
Static Public Attributes inherited from MediaWikiTestCase | |
static | $users |
Static Protected Member Functions inherited from MediaWikiTestCase | |
static | stripStringKeys (&$r) |
Utility function for eliminating all string keys from an array. More... | |
Protected Attributes inherited from MediaWikiTestCase | |
DatabaseBase | $db |
array | $supportedDBs |
array | $tablesUsed = array() |
@group Database ^— needed for language cache stuff
@group Title
Definition at line 9 of file TitleTest.php.
TitleTest::dataTestIsValidMoveOperation | ( | ) |
Provides test parameter values for testIsValidMoveOperation()
Definition at line 270 of file TitleTest.php.
References array().
TitleTest::dataWgWhitelistReadRegexp | ( | ) |
Provides test parameter values for testWgWhitelistReadRegexp()
Definition at line 345 of file TitleTest.php.
References array().
TitleTest::flattenErrorsArray | ( | $errors | ) |
Definition at line 381 of file TitleTest.php.
References $error, array(), and as.
Referenced by testIsValidMoveOperation(), and testWgWhitelistReadRegexp().
|
static |
Definition at line 472 of file TitleTest.php.
|
static |
Definition at line 235 of file TitleTest.php.
References array().
|
static |
Definition at line 149 of file TitleTest.php.
References array().
TitleTest::provideGetFragment | ( | ) |
Definition at line 562 of file TitleTest.php.
References array().
|
static |
Definition at line 421 of file TitleTest.php.
References array().
TitleTest::provideGetTitleValue | ( | ) |
Definition at line 541 of file TitleTest.php.
References array().
TitleTest::provideNewFromTitleValue | ( | ) |
Definition at line 521 of file TitleTest.php.
|
static |
Definition at line 492 of file TitleTest.php.
|
static |
Definition at line 513 of file TitleTest.php.
|
static |
Definition at line 390 of file TitleTest.php.
References array().
|
protected |
Reimplemented from MediaWikiTestCase.
Definition at line 10 of file TitleTest.php.
References array(), Language\factory(), and MediaWikiTestCase\setMwGlobals().
TitleTest::testBug31100FixSpecialName | ( | $text, | |
$expectedParam | |||
) |
@dataProvider provideBug31100 @covers Title::fixSpecialName
Definition at line 223 of file TitleTest.php.
References $title, and Title\newFromText().
TitleTest::testConvertByteClassToUnicodeClass | ( | $byteClass, | |
$unicodeClass | |||
) |
@dataProvider provideConvertByteClassToUnicodeClass @covers Title::convertByteClassToUnicodeClass
Definition at line 214 of file TitleTest.php.
References Title\convertByteClassToUnicodeClass().
TitleTest::testGetBaseText | ( | $title, | |
$expected, | |||
$msg = '' |
|||
) |
@dataProvider provideBaseTitleCases @covers Title::getBaseText
Definition at line 464 of file TitleTest.php.
References $title, and Title\newFromText().
TitleTest::testGetFragment | ( | $full, | |
$fragment | |||
) |
@dataProvider provideGetFragment
$full | |
$fragment |
Definition at line 586 of file TitleTest.php.
References $title, and Title\newFromText().
TitleTest::testGetPageViewLanguage | ( | $expected, | |
$titleText, | |||
$contLang, | |||
$lang, | |||
$variant, | |||
$msg = '' |
|||
) |
@dataProvider provideGetPageViewLanguage @covers Title::getPageViewLanguage
Definition at line 401 of file TitleTest.php.
References $title, $wgContLang, $wgLang, Language\factory(), global, and Title\newFromText().
TitleTest::testGetRootText | ( | $title, | |
$expected, | |||
$msg = '' |
|||
) |
@dataProvider provideRootTitleCases @covers Title::getRootText
Definition at line 484 of file TitleTest.php.
References $title, and Title\newFromText().
TitleTest::testGetSubpageText | ( | $title, | |
$expected, | |||
$msg = '' |
|||
) |
Definition at line 505 of file TitleTest.php.
References $title, and Title\newFromText().
TitleTest::testGetTitleValue | ( | $text | ) |
@dataProvider provideGetTitleValue
Definition at line 552 of file TitleTest.php.
References $title, $value, and Title\newFromText().
TitleTest::testIsValidMoveOperation | ( | $source, | |
$target, | |||
$expected | |||
) |
Auth-less test of Title::isValidMoveOperation.
@group Database
string | $source | |
string | $target | |
array | string | bool | $expected | Required error @dataProvider provideTestIsValidMoveOperation @covers Title::isValidMoveOperation |
Definition at line 253 of file TitleTest.php.
References $error, $source, $title, array(), as, flattenErrorsArray(), and Title\newFromText().
TitleTest::testLegalChars | ( | ) |
@covers Title::legalChars
Definition at line 26 of file TitleTest.php.
References as, and Title\legalChars().
TitleTest::testNewFromTitleValue | ( | TitleValue | $value | ) |
@dataProvider provideNewFromTitleValue
Definition at line 532 of file TitleTest.php.
References $title, $value, and Title\newFromTitleValue().
TitleTest::testSecureAndSplit | ( | ) |
See also mediawiki.Title.test.js @covers Title::secureAndSplit.
Definition at line 45 of file TitleTest.php.
References array(), as, Title\newFromText(), and MediaWikiTestCase\setMwGlobals().
TitleTest::testWgWhitelistReadRegexp | ( | $whitelistRegexp, | |
$source, | |||
$action, | |||
$expected | |||
) |
Auth-less test of Title::userCan.
array | $whitelistRegexp | |
string | $source | |
string | $action | |
array | string | bool | $expected | Required error |
@covers Title::checkReadPermissions @dataProvider dataWgWhitelistReadRegexp
Definition at line 288 of file TitleTest.php.
References $error, $source, $title, $wgUser, array(), as, flattenErrorsArray(), global, and Title\newFromDBkey().