MediaWiki  master
ImagePageTest Class Reference
Inheritance diagram for ImagePageTest:
Collaboration diagram for ImagePageTest:

Public Member Functions

 getImagePage ( $filename)
 
 provideGetLanguageForRendering ()
 
 providerGetDisplayWidthHeight ()
 
 providerGetThumbSizes ()
 
 setUp ()
 
 testGetDisplayWidthHeight ( $dim, $expected)
 ImagePage::getDisplayWidthHeight providerGetDisplayWidthHeight. More...
 
 testGetLanguageForRendering ( $expected=null, $wikiLangCode, $lang=null)
 ImagePage::getLanguageForRendering() provideGetLanguageForRendering. More...
 
 testGetThumbSizes ( $filename, $expectedNumberThumbs)
 ImagePage::getThumbSizes providerGetThumbSizes. More...
 

Additional Inherited Members

- Protected Member Functions inherited from MediaWikiMediaTestCase
 createsThumbnails ()
 Will the test create thumbnails (and thus do we need to set aside a temporary directory for them?) More...
 
 dataFile ( $name, $type=false)
 Utility function: Get a new file object for a file on disk but not actually in db. More...
 
 getFilePath ()
 The result of this method will set the file path to use, as well as the protected member $filePath. More...
 
 getRepoOptions ()
 
 setUp ()
 
- Protected Attributes inherited from MediaWikiMediaTestCase
FSFileBackend $backend
 
string $filePath
 
FileRepo $repo
 

Detailed Description

Definition at line 5 of file ImagePageTest.php.

Member Function Documentation

◆ getImagePage()

ImagePageTest::getImagePage (   $filename)

◆ provideGetLanguageForRendering()

ImagePageTest::provideGetLanguageForRendering ( )

Definition at line 120 of file ImagePageTest.php.

References null.

◆ providerGetDisplayWidthHeight()

ImagePageTest::providerGetDisplayWidthHeight ( )

Definition at line 42 of file ImagePageTest.php.

◆ providerGetThumbSizes()

ImagePageTest::providerGetThumbSizes ( )

Definition at line 87 of file ImagePageTest.php.

◆ setUp()

ImagePageTest::setUp ( )

Definition at line 7 of file ImagePageTest.php.

◆ testGetDisplayWidthHeight()

ImagePageTest::testGetDisplayWidthHeight (   $dim,
  $expected 
)

ImagePage::getDisplayWidthHeight providerGetDisplayWidthHeight.

Parameters
array$dimArray [maxWidth, maxHeight, width, height]
array$expectedArray [width, height] The width and height we expect to display at

Definition at line 32 of file ImagePageTest.php.

References getImagePage().

◆ testGetLanguageForRendering()

ImagePageTest::testGetLanguageForRendering (   $expected = null,
  $wikiLangCode,
  $lang = null 
)

ImagePage::getLanguageForRendering() provideGetLanguageForRendering.

Parameters
string | null$expectedExpected language code
string$wikiLangCodeWiki language code
string | null$langlang=... URL parameter

Definition at line 104 of file ImagePageTest.php.

References $lang, $params, $request, getImagePage(), and null.

◆ testGetThumbSizes()

ImagePageTest::testGetThumbSizes (   $filename,
  $expectedNumberThumbs 
)

ImagePage::getThumbSizes providerGetThumbSizes.

Parameters
string$filename
int$expectedNumberThumbsHow many thumbnails to show

Definition at line 77 of file ImagePageTest.php.

References getImagePage().


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