mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/PageImages
synced 2024-11-27 17:50:53 +00:00
build: Updating mediawiki/mediawiki-codesniffer to 29.0.0
Additional changes: * Also sorted "composer fix" command to run phpcbf last. Change-Id: I5e714b548aa11857b5631df94c075fa0e4e7ce81
This commit is contained in:
parent
586a64e657
commit
712d006ba3
|
@ -2,14 +2,14 @@
|
|||
"require-dev": {
|
||||
"jakub-onderka/php-parallel-lint": "1.0.0",
|
||||
"jakub-onderka/php-console-highlighter": "0.3.2",
|
||||
"mediawiki/mediawiki-codesniffer": "28.0.0",
|
||||
"mediawiki/mediawiki-codesniffer": "29.0.0",
|
||||
"mediawiki/minus-x": "0.3.2",
|
||||
"mediawiki/mediawiki-phan-config": "0.9.0"
|
||||
},
|
||||
"scripts": {
|
||||
"fix": [
|
||||
"phpcbf",
|
||||
"minus-x fix ."
|
||||
"minus-x fix .",
|
||||
"phpcbf"
|
||||
],
|
||||
"test": [
|
||||
"parallel-lint . --exclude vendor --exclude node_modules",
|
||||
|
|
|
@ -9,8 +9,8 @@ use FormatMetadata;
|
|||
use Http;
|
||||
use LinksUpdate;
|
||||
use PageImages;
|
||||
use Title;
|
||||
use Revision;
|
||||
use Title;
|
||||
|
||||
/**
|
||||
* Handler for the "LinksUpdate" hook.
|
||||
|
|
|
@ -64,7 +64,7 @@ class ApiQueryPageImagesTest extends \PHPUnit\Framework\TestCase {
|
|||
public function testGetAllowedParams() {
|
||||
$instance = $this->newInstance();
|
||||
$params = $instance->getAllowedParams();
|
||||
$this->assertInternalType( 'array', $params );
|
||||
$this->assertIsArray( $params );
|
||||
$this->assertNotEmpty( $params );
|
||||
$this->assertContainsOnly( 'array', $params );
|
||||
$this->assertArrayHasKey( 'limit', $params );
|
||||
|
|
|
@ -3,10 +3,10 @@
|
|||
namespace PageImages\Tests\Hooks;
|
||||
|
||||
use LinksUpdate;
|
||||
use MediaWikiTestCase;
|
||||
use PageImages;
|
||||
use PageImages\Hooks\LinksUpdateHookHandler;
|
||||
use ParserOutput;
|
||||
use MediaWikiTestCase;
|
||||
use RepoGroup;
|
||||
use Title;
|
||||
use Wikimedia\TestingAccessWrapper;
|
||||
|
@ -148,13 +148,13 @@ class LinksUpdateHookHandlerTest extends MediaWikiTestCase {
|
|||
$mock->doLinksUpdate( $linksUpdate );
|
||||
|
||||
$this->assertTrue( property_exists( $linksUpdate, 'mProperties' ), 'precondition' );
|
||||
if ( is_null( $expectedFreeFileName ) ) {
|
||||
if ( $expectedFreeFileName === null ) {
|
||||
$this->assertArrayNotHasKey( PageImages::PROP_NAME_FREE, $linksUpdate->mProperties );
|
||||
} else {
|
||||
$this->assertSame( $expectedFreeFileName,
|
||||
$linksUpdate->mProperties[PageImages::PROP_NAME_FREE] );
|
||||
}
|
||||
if ( is_null( $expectedNonFreeFileName ) ) {
|
||||
if ( $expectedNonFreeFileName === null ) {
|
||||
$this->assertArrayNotHasKey( PageImages::PROP_NAME, $linksUpdate->mProperties );
|
||||
} else {
|
||||
$this->assertSame( $expectedNonFreeFileName, $linksUpdate->mProperties[PageImages::PROP_NAME] );
|
||||
|
|
Loading…
Reference in a new issue