Use SpecialPage::getLinkRenderer and pass it to the pagers Since I082152b64141f1a9a4085bba23fe81a99ec8d886 it is a property in the IndexPager and can be used by getLinkRenderer Change-Id: I2be8a8b9f2b0b8c04fe9e18aa1959987fc125f50
25 lines
678 B
PHP
25 lines
678 B
PHP
<?php
|
|
|
|
use MediaWiki\MediaWikiServices;
|
|
|
|
/**
|
|
* Test class for ImageListPagerTest class.
|
|
*
|
|
* Copyright © 2013, Antoine Musso
|
|
* Copyright © 2013, Siebrand Mazeland
|
|
* Copyright © 2013, Wikimedia Foundation Inc.
|
|
*
|
|
* @group Database
|
|
*/
|
|
class ImageListPagerTest extends MediaWikiTestCase {
|
|
/**
|
|
* @expectedException MWException
|
|
* @expectedExceptionMessage invalid_field
|
|
* @covers ImageListPager::formatValue
|
|
*/
|
|
public function testFormatValuesThrowException() {
|
|
$page = new ImageListPager( RequestContext::getMain(), null, '', false, false,
|
|
MediaWikiServices::getInstance()->getLinkRenderer() );
|
|
$page->formatValue( 'invalid_field', 'invalid_value' );
|
|
}
|
|
}
|