MediaWiki  master
TitleMethodsTest Class Reference

ContentHandler Database. More...

Inheritance diagram for TitleMethodsTest:
Collaboration diagram for TitleMethodsTest:

Public Member Functions

 dataGetContentModel ()
 
 provideGetLinkURL ()
 
 tearDown ()
 
 testClearCaches ()
 Title::clearCaches. More...
 
 testGetContentModel ( $title, $expectedModelId)
 dataGetContentModel Title::getContentModel More...
 
 testGetLinkURL ( $expected, $ns, $title, $fragment='', $interwiki='', $query='', $query2=false, $proto=false)
 provideGetLinkURL More...
 
 testGetOtherPage ( $text, $expected)
 provideGetOtherpage Title::getOtherPage More...
 
 testHasContentModel ( $title, $expectedModelId)
 dataGetContentModel Title::hasContentModel More...
 
 testHasSubjectNamespace ( $title, $ns, $expectedBool)
 provideHasSubjectNamespace Title::hasSubjectNamespace More...
 
 testInNamespace ( $title, $ns, $expectedBool)
 provideInNamespace Title::inNamespace More...
 
 testInNamespaces ()
 Title::inNamespaces. More...
 
 testIsUserConfigPage ( $title, $expectedBool)
 provideIsUserConfigPage Title::isUserConfigPage More...
 
 testIsUserCssConfigPage ( $title, $expectedBool)
 provideIsUserCssConfigPage Title::isUserCssConfigPage More...
 
 testIsUserJsConfigPage ( $title, $expectedBool)
 provideIsUserJsConfigPage Title::isUserJsConfigPage More...
 
 testIsWikitextPage ( $title, $expectedBool)
 provideIsWikitextPage Title::isWikitextPage More...
 
 testSiteConfigPage ( $title, $expectedBool)
 provideIsSiteConfigPage Title::isSiteConfigPage More...
 
 testTitleMoveCompleteIntegrationTest ()
 Integration test to catch regressions like T74870. More...
 

Static Public Member Functions

static provideGetOtherPage ()
 
static provideHasSubjectNamespace ()
 
static provideInNamespace ()
 
static provideIsSiteConfigPage ()
 
static provideIsUserConfigPage ()
 
static provideIsUserCssConfigPage ()
 
static provideIsUserJsConfigPage ()
 
static provideIsWikitextPage ()
 

Protected Member Functions

 setUp ()
 
- Protected Member Functions inherited from MediaWikiLangTestCase
 setUp ()
 

Detailed Description

ContentHandler Database.

Note
We don't make assumptions about the main namespace. But we do expect the Help namespace to contain Wikitext.

Definition at line 13 of file TitleMethodsTest.php.

Member Function Documentation

◆ dataGetContentModel()

TitleMethodsTest::dataGetContentModel ( )

◆ provideGetLinkURL()

TitleMethodsTest::provideGetLinkURL ( )

Definition at line 333 of file TitleMethodsTest.php.

References NS_MAIN.

◆ provideGetOtherPage()

static TitleMethodsTest::provideGetOtherPage ( )
static

Definition at line 290 of file TitleMethodsTest.php.

References null.

◆ provideHasSubjectNamespace()

static TitleMethodsTest::provideHasSubjectNamespace ( )
static

Definition at line 67 of file TitleMethodsTest.php.

References false, NS_MAIN, NS_TALK, NS_TEMPLATE, NS_USER, NS_USER_TALK, and true.

◆ provideInNamespace()

static TitleMethodsTest::provideInNamespace ( )
static

Definition at line 34 of file TitleMethodsTest.php.

References false, NS_MAIN, NS_TALK, NS_TEMPLATE, NS_USER, NS_USER_TALK, and true.

◆ provideIsSiteConfigPage()

static TitleMethodsTest::provideIsSiteConfigPage ( )
static

Definition at line 132 of file TitleMethodsTest.php.

References false, and true.

◆ provideIsUserConfigPage()

static TitleMethodsTest::provideIsUserConfigPage ( )
static

Definition at line 170 of file TitleMethodsTest.php.

References false, and true.

◆ provideIsUserCssConfigPage()

static TitleMethodsTest::provideIsUserCssConfigPage ( )
static

Definition at line 207 of file TitleMethodsTest.php.

References false, and true.

◆ provideIsUserJsConfigPage()

static TitleMethodsTest::provideIsUserJsConfigPage ( )
static

Definition at line 230 of file TitleMethodsTest.php.

References false, and true.

◆ provideIsWikitextPage()

static TitleMethodsTest::provideIsWikitextPage ( )
static

Definition at line 253 of file TitleMethodsTest.php.

References false, and true.

◆ setUp()

TitleMethodsTest::setUp ( )
protected

Definition at line 15 of file TitleMethodsTest.php.

References CONTENT_MODEL_JAVASCRIPT.

◆ tearDown()

TitleMethodsTest::tearDown ( )

Definition at line 465 of file TitleMethodsTest.php.

References Title\clearCaches().

◆ testClearCaches()

TitleMethodsTest::testClearCaches ( )

◆ testGetContentModel()

TitleMethodsTest::testGetContentModel (   $title,
  $expectedModelId 
)

dataGetContentModel Title::getContentModel

Definition at line 118 of file TitleMethodsTest.php.

References $title, and Title\newFromText().

◆ testGetLinkURL()

TitleMethodsTest::testGetLinkURL (   $expected,
  $ns,
  $title,
  $fragment = '',
  $interwiki = '',
  $query = '',
  $query2 = false,
  $proto = false 
)

◆ testGetOtherPage()

TitleMethodsTest::testGetOtherPage (   $text,
  $expected 
)

provideGetOtherpage Title::getOtherPage

Parameters
string$text
string | null$expected

Definition at line 308 of file TitleMethodsTest.php.

References $title, class, Title\newFromText(), and null.

◆ testHasContentModel()

TitleMethodsTest::testHasContentModel (   $title,
  $expectedModelId 
)

dataGetContentModel Title::hasContentModel

Definition at line 127 of file TitleMethodsTest.php.

References $title, and Title\newFromText().

◆ testHasSubjectNamespace()

TitleMethodsTest::testHasSubjectNamespace (   $title,
  $ns,
  $expectedBool 
)

provideHasSubjectNamespace Title::hasSubjectNamespace

Definition at line 84 of file TitleMethodsTest.php.

References $title, and Title\newFromText().

◆ testInNamespace()

TitleMethodsTest::testInNamespace (   $title,
  $ns,
  $expectedBool 
)

provideInNamespace Title::inNamespace

Definition at line 51 of file TitleMethodsTest.php.

References $title, and Title\newFromText().

◆ testInNamespaces()

TitleMethodsTest::testInNamespaces ( )

◆ testIsUserConfigPage()

TitleMethodsTest::testIsUserConfigPage (   $title,
  $expectedBool 
)

provideIsUserConfigPage Title::isUserConfigPage

Definition at line 202 of file TitleMethodsTest.php.

References $title, and Title\newFromText().

◆ testIsUserCssConfigPage()

TitleMethodsTest::testIsUserCssConfigPage (   $title,
  $expectedBool 
)

provideIsUserCssConfigPage Title::isUserCssConfigPage

Definition at line 225 of file TitleMethodsTest.php.

References $title, and Title\newFromText().

◆ testIsUserJsConfigPage()

TitleMethodsTest::testIsUserJsConfigPage (   $title,
  $expectedBool 
)

provideIsUserJsConfigPage Title::isUserJsConfigPage

Definition at line 248 of file TitleMethodsTest.php.

References $title, and Title\newFromText().

◆ testIsWikitextPage()

TitleMethodsTest::testIsWikitextPage (   $title,
  $expectedBool 
)

provideIsWikitextPage Title::isWikitextPage

Definition at line 285 of file TitleMethodsTest.php.

References $title, and Title\newFromText().

◆ testSiteConfigPage()

TitleMethodsTest::testSiteConfigPage (   $title,
  $expectedBool 
)

provideIsSiteConfigPage Title::isSiteConfigPage

Definition at line 165 of file TitleMethodsTest.php.

References $title, and Title\newFromText().

◆ testTitleMoveCompleteIntegrationTest()

TitleMethodsTest::testTitleMoveCompleteIntegrationTest ( )

Integration test to catch regressions like T74870.

Taken and modified from SemanticMediaWiki

Title::moveTo

Definition at line 446 of file TitleMethodsTest.php.

References $oldTitle, WikiPage\factory(), and Title\newFromText().


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