diff --git a/.phpcs.xml b/.phpcs.xml
index 74726969016..5ccd941502d 100644
--- a/.phpcs.xml
+++ b/.phpcs.xml
@@ -60,6 +60,7 @@
*/languages/messages/*
+ */tests/*
", "<!-- Foo -->" ],
@@ -185,7 +184,6 @@ class PreprocessorTest extends MediaWikiIntegrationTestCase {
* These are more complex test cases taken out of wiki articles.
*/
public static function provideFiles() {
- // phpcs:disable Generic.Files.LineLength
return [
[ "QuoteQuran" ], # https://en.wikipedia.org/w/index.php?title=Template:QuoteQuran/sandbox&oldid=237348988 GFDL + CC BY-SA by Striver
[ "Factorial" ], # https://en.wikipedia.org/w/index.php?title=Template:Factorial&oldid=98548758 GFDL + CC BY-SA by Polonium
@@ -219,7 +217,6 @@ class PreprocessorTest extends MediaWikiIntegrationTestCase {
* Tests from T30642 ยท https://phabricator.wikimedia.org/T30642
*/
public static function provideHeadings() {
- // phpcs:disable Generic.Files.LineLength
return [
/* These should become headings: */
[ "== h ==", "== h ==<!--c1-->" ],
diff --git a/tests/phpunit/includes/resourceloader/ResourceLoaderClientHtmlTest.php b/tests/phpunit/includes/resourceloader/ResourceLoaderClientHtmlTest.php
index 6cf7ef69ff0..603b5d51c51 100644
--- a/tests/phpunit/includes/resourceloader/ResourceLoaderClientHtmlTest.php
+++ b/tests/phpunit/includes/resourceloader/ResourceLoaderClientHtmlTest.php
@@ -102,8 +102,6 @@ class ResourceLoaderClientHtmlTest extends PHPUnit\Framework\TestCase {
$client->setExemptStates( [
'test.exempt' => 'ready',
] );
-
- // phpcs:disable Generic.Files.LineLength
$expected = '' . "\n"
. '';
// phpcs:enable
@@ -147,8 +143,6 @@ class ResourceLoaderClientHtmlTest extends PHPUnit\Framework\TestCase {
self::makeContext(),
[ 'safemode' => '1' ]
);
-
- // phpcs:disable Generic.Files.LineLength
$expected = '' . "\n"
. '';
// phpcs:enable
@@ -164,8 +158,6 @@ class ResourceLoaderClientHtmlTest extends PHPUnit\Framework\TestCase {
self::makeContext(),
[ 'target' => null ]
);
-
- // phpcs:disable Generic.Files.LineLength
$expected = '' . "\n"
. '';
// phpcs:enable
@@ -186,7 +178,6 @@ class ResourceLoaderClientHtmlTest extends PHPUnit\Framework\TestCase {
$client->setModuleStyles( [
'test.styles.deprecated',
] );
- // phpcs:disable Generic.Files.LineLength
$expected = '';
@@ -196,7 +187,6 @@ class ResourceLoaderClientHtmlTest extends PHPUnit\Framework\TestCase {
}
public static function provideMakeLoad() {
- // phpcs:disable Generic.Files.LineLength
return [
[
'context' => [],
diff --git a/tests/phpunit/includes/resourceloader/ResourceLoaderSkinModuleTest.php b/tests/phpunit/includes/resourceloader/ResourceLoaderSkinModuleTest.php
index 9eb959ebb5c..48deb71b48b 100644
--- a/tests/phpunit/includes/resourceloader/ResourceLoaderSkinModuleTest.php
+++ b/tests/phpunit/includes/resourceloader/ResourceLoaderSkinModuleTest.php
@@ -163,7 +163,6 @@ class ResourceLoaderSkinModuleTest extends ResourceLoaderTestCase {
}
public static function provideGetStyles() {
- // phpcs:disable Generic.Files.LineLength
return [
[
'parent' => [],
diff --git a/tests/phpunit/includes/upload/UploadBaseTest.php b/tests/phpunit/includes/upload/UploadBaseTest.php
index 41ea070fc9b..2cbd1db5934 100644
--- a/tests/phpunit/includes/upload/UploadBaseTest.php
+++ b/tests/phpunit/includes/upload/UploadBaseTest.php
@@ -138,7 +138,6 @@ class UploadBaseTest extends MediaWikiIntegrationTestCase {
}
public static function provideCheckSvgScriptCallback() {
- // phpcs:disable Generic.Files.LineLength
return [
// html5sec SVG vectors
[
diff --git a/tests/phpunit/includes/utils/MWCryptHKDFTest.php b/tests/phpunit/includes/utils/MWCryptHKDFTest.php
index 4957390848b..729d1e8d635 100644
--- a/tests/phpunit/includes/utils/MWCryptHKDFTest.php
+++ b/tests/phpunit/includes/utils/MWCryptHKDFTest.php
@@ -40,7 +40,6 @@ class MWCryptHKDFTest extends MediaWikiIntegrationTestCase {
* Test vectors from Appendix A on https://tools.ietf.org/html/rfc5869
*/
public static function providerRfc5869() {
- // phpcs:disable Generic.Files.LineLength
return [
// A.1
[
diff --git a/tests/phpunit/integration/includes/CommentFormatter/CommentParserTest.php b/tests/phpunit/integration/includes/CommentFormatter/CommentParserTest.php
index b8b2f17672d..5e43866a362 100644
--- a/tests/phpunit/integration/includes/CommentFormatter/CommentParserTest.php
+++ b/tests/phpunit/integration/includes/CommentFormatter/CommentParserTest.php
@@ -72,8 +72,6 @@ class CommentParserTest extends \MediaWikiIntegrationTestCase {
*/
public function provideFormatComment() {
$wikiId = 'enwiki'; // $wgConf has a fake entry for this
-
- // phpcs:disable Generic.Files.LineLength
return [
// Linker::formatComment
[
@@ -319,7 +317,6 @@ class CommentParserTest extends \MediaWikiIntegrationTestCase {
* Adapted from LinkerTest
*/
public static function provideFormatLinksInComment() {
- // phpcs:disable Generic.Files.LineLength
return [
[
'foo bar Special:BlankPage',
@@ -390,7 +387,6 @@ class CommentParserTest extends \MediaWikiIntegrationTestCase {
] );
$expected = [
'Present',
- // phpcs:ignore Generic.Files.LineLength
'Absent'
];
$this->assertSame( $expected, $result );
diff --git a/tests/phpunit/languages/LanguageIntegrationTest.php b/tests/phpunit/languages/LanguageIntegrationTest.php
index a26269dcba6..d33e908f206 100644
--- a/tests/phpunit/languages/LanguageIntegrationTest.php
+++ b/tests/phpunit/languages/LanguageIntegrationTest.php
@@ -1363,7 +1363,6 @@ class LanguageIntegrationTest extends LanguageClassesTestCase {
}
public static function provideCheckTitleEncodingData() {
- // phpcs:disable Generic.Files.LineLength
return [
[ "" ],
[ "United States of America" ], // 7bit ASCII
diff --git a/tests/phpunit/maintenance/backupPrefetchTest.php b/tests/phpunit/maintenance/backupPrefetchTest.php
index 224aaeaf8d9..39f6b665740 100644
--- a/tests/phpunit/maintenance/backupPrefetchTest.php
+++ b/tests/phpunit/maintenance/backupPrefetchTest.php
@@ -166,7 +166,6 @@ class BaseDumpTest extends MediaWikiIntegrationTestCase {
$fname = $this->getNewTempFile();
// The header of every prefetch file
- // phpcs:ignore Generic.Files.LineLength
$header = '
wikisvn
diff --git a/tests/phpunit/unit/includes/ParamValidator/TypeDef/NamespaceDefTest.php b/tests/phpunit/unit/includes/ParamValidator/TypeDef/NamespaceDefTest.php
index 5f3d397bbc5..9c9636e8ca4 100644
--- a/tests/phpunit/unit/includes/ParamValidator/TypeDef/NamespaceDefTest.php
+++ b/tests/phpunit/unit/includes/ParamValidator/TypeDef/NamespaceDefTest.php
@@ -262,7 +262,6 @@ class NamespaceDefTest extends TypeDefTestCase {
[],
[ 'type' => 'namespace' ],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '10123456789101112131415
16',
ParamValidator::PARAM_ISMULTI => null,
],
@@ -275,7 +274,6 @@ class NamespaceDefTest extends TypeDefTestCase {
],
[ 'type' => 'namespace', 'extranamespaces' => [ NS_SPECIAL, NS_MEDIA ] ],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '1-1-20123456789101112131415
18',
ParamValidator::PARAM_ISMULTI => null,
],
@@ -291,7 +289,6 @@ class NamespaceDefTest extends TypeDefTestCase {
],
],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '1-1-20123456789101112131415
18',
ParamValidator::PARAM_ISMULTI => null,
],
diff --git a/tests/phpunit/unit/includes/ParamValidator/TypeDef/UserDefTest.php b/tests/phpunit/unit/includes/ParamValidator/TypeDef/UserDefTest.php
index 03494c67c79..e9c80d7ec37 100644
--- a/tests/phpunit/unit/includes/ParamValidator/TypeDef/UserDefTest.php
+++ b/tests/phpunit/unit/includes/ParamValidator/TypeDef/UserDefTest.php
@@ -364,7 +364,6 @@ class UserDefTest extends TypeDefTestCase {
'subtypes' => [ 'name', 'ip', 'cidr', 'interwiki' ],
],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '1
4',
],
],
@@ -378,7 +377,6 @@ class UserDefTest extends TypeDefTestCase {
'subtypes' => [ 'name', 'id' ],
],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '2
2',
],
],
diff --git a/tests/phpunit/unit/includes/language/LCStoreStaticArrayTest.php b/tests/phpunit/unit/includes/language/LCStoreStaticArrayTest.php
index 32a78b188ea..8a1234f6e15 100644
--- a/tests/phpunit/unit/includes/language/LCStoreStaticArrayTest.php
+++ b/tests/phpunit/unit/includes/language/LCStoreStaticArrayTest.php
@@ -1,5 +1,4 @@
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_ISMULTI_LIMIT2 => 'PARAM_ISMULTI_LIMIT2 must be greater than or equal to PARAM_ISMULTI_LIMIT1, but 10 < 100',
],
'allowedKeys' => $multiKeys,
@@ -1093,7 +1092,6 @@ class ParamValidatorTest extends \PHPUnit\Framework\TestCase {
[
ParamValidator::PARAM_DEPRECATED => '',
ParamValidator::PARAM_REQUIRED => '',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_DEFAULT => '1234',
],
],
@@ -1105,13 +1103,9 @@ class ParamValidatorTest extends \PHPUnit\Framework\TestCase {
ParamValidator::PARAM_DEFAULT => '',
],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_ISMULTI => '',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_ISMULTI_LIMIT1 => '50500',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_ALL => '*',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_DEFAULT => '',
],
],
@@ -1120,9 +1114,7 @@ class ParamValidatorTest extends \PHPUnit\Framework\TestCase {
ParamValidator::PARAM_ISMULTI => true,
],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_ISMULTI => '',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_ISMULTI_LIMIT1 => '50500',
],
[],
@@ -1136,11 +1128,8 @@ class ParamValidatorTest extends \PHPUnit\Framework\TestCase {
ParamValidator::PARAM_ALL => 'all',
],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_ISMULTI => '',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_ISMULTI_LIMIT1 => '1015',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_ALL => 'all',
],
],
@@ -1150,9 +1139,7 @@ class ParamValidatorTest extends \PHPUnit\Framework\TestCase {
ParamValidator::PARAM_ISMULTI_LIMIT2 => 10,
],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_ISMULTI => '',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_ISMULTI_LIMIT1 => '50',
],
],
@@ -1164,7 +1151,6 @@ class ParamValidatorTest extends \PHPUnit\Framework\TestCase {
ParamValidator::PARAM_ISMULTI_LIMIT2 => 2,
],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_ISMULTI => '',
],
],
@@ -1176,9 +1162,7 @@ class ParamValidatorTest extends \PHPUnit\Framework\TestCase {
ParamValidator::PARAM_ISMULTI_LIMIT2 => 10,
],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_ISMULTI => '',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_ISMULTI_LIMIT1 => '410',
],
],
@@ -1191,9 +1175,7 @@ class ParamValidatorTest extends \PHPUnit\Framework\TestCase {
ParamValidator::PARAM_ALLOW_DUPLICATES => true,
],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_ISMULTI => '',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_ISMULTI_LIMIT1 => '4',
],
],
@@ -1206,10 +1188,8 @@ class ParamValidatorTest extends \PHPUnit\Framework\TestCase {
[
ParamValidator::PARAM_REQUIRED => '',
ParamValidator::PARAM_TYPE => '',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_ISMULTI_LIMIT1 => '50500',
'foobar' => '',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_DEFAULT => 'XX',
],
[
diff --git a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/BooleanDefTest.php b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/BooleanDefTest.php
index 744b4e373f6..0dc24273261 100644
--- a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/BooleanDefTest.php
+++ b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/BooleanDefTest.php
@@ -59,7 +59,6 @@ class BooleanDefTest extends TypeDefTestCase {
[],
[],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '1',
],
],
@@ -67,7 +66,6 @@ class BooleanDefTest extends TypeDefTestCase {
[ ParamValidator::PARAM_ISMULTI => true ],
[],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '2',
],
],
diff --git a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/EnumDefTest.php b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/EnumDefTest.php
index b42ff76380c..6c4c2a775f2 100644
--- a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/EnumDefTest.php
+++ b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/EnumDefTest.php
@@ -118,7 +118,6 @@ class EnumDefTest extends TypeDefTestCase {
[
'issues' => [
'X',
- // phpcs:disable Generic.Files.LineLength
'Values in PARAM_DEPRECATED_VALUES must be null, true, or MessageValue, but value for "c" is false',
'Values in PARAM_DEPRECATED_VALUES must be null, true, or MessageValue, but value for "f" is string',
'Values in PARAM_DEPRECATED_VALUES must be null, true, or MessageValue, but value for "g" is ' . static::class,
@@ -161,7 +160,6 @@ class EnumDefTest extends TypeDefTestCase {
'type' => [ 'a', 'b', 'c', 'd' ],
],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '1abcd
4',
ParamValidator::PARAM_ISMULTI => null,
],
@@ -175,7 +173,6 @@ class EnumDefTest extends TypeDefTestCase {
'type' => [ 'a', 'b', 'c', 'd' ],
],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '2abcd
4',
ParamValidator::PARAM_ISMULTI => null,
],
@@ -190,7 +187,6 @@ class EnumDefTest extends TypeDefTestCase {
'deprecatedvalues' => [ 'b', 'c' ],
],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '1adbc
4',
ParamValidator::PARAM_ISMULTI => null,
],
@@ -204,7 +200,6 @@ class EnumDefTest extends TypeDefTestCase {
'type' => [ 'a', 'b', 'c', 'd' ],
],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '1abcd
4',
ParamValidator::PARAM_ISMULTI => null,
],
@@ -217,7 +212,6 @@ class EnumDefTest extends TypeDefTestCase {
'type' => [ '', 'a', 'b', 'c', 'd' ],
],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '1abcd
45',
ParamValidator::PARAM_ISMULTI => null,
],
diff --git a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/ExpiryDefTest.php b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/ExpiryDefTest.php
index d2e8a613b88..a146a7acd08 100644
--- a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/ExpiryDefTest.php
+++ b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/ExpiryDefTest.php
@@ -137,7 +137,6 @@ class ExpiryDefTest extends TypeDefTestCase {
[],
[],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
'param-type' => '1"infinite""indefinite""infinity""never"
'
]
]
diff --git a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/FloatDefTest.php b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/FloatDefTest.php
index 63163e93a27..446711313ef 100644
--- a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/FloatDefTest.php
+++ b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/FloatDefTest.php
@@ -160,7 +160,6 @@ class FloatDefTest extends TypeDefTestCase {
[],
[ 'min' => null, 'max' => null ],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '1',
],
],
@@ -172,9 +171,7 @@ class FloatDefTest extends TypeDefTestCase {
],
[ 'min' => 1, 'max' => 100 ],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
FloatDef::PARAM_MIN => '21100',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '2',
],
],
diff --git a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/IntegerDefTest.php b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/IntegerDefTest.php
index 6e47a1548cc..69b4f1bda07 100644
--- a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/IntegerDefTest.php
+++ b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/IntegerDefTest.php
@@ -264,7 +264,6 @@ class IntegerDefTest extends TypeDefTestCase {
[],
[ 'min' => null, 'max' => null ],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '1',
],
],
@@ -272,9 +271,7 @@ class IntegerDefTest extends TypeDefTestCase {
[ IntegerDef::PARAM_MIN => 0, ParamValidator::PARAM_ISMULTI => true ],
[ 'min' => 0, 'max' => null ],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
IntegerDef::PARAM_MIN => '20โ',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '2',
],
],
@@ -282,9 +279,7 @@ class IntegerDefTest extends TypeDefTestCase {
[ IntegerDef::PARAM_MAX => 2 ],
[ 'min' => null, 'max' => 2 ],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
IntegerDef::PARAM_MIN => '1โโ2',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '1',
],
],
@@ -292,9 +287,7 @@ class IntegerDefTest extends TypeDefTestCase {
[ IntegerDef::PARAM_MAX => 2, IntegerDef::PARAM_MAX2 => 4 ],
[ 'min' => null, 'max' => 2, 'highmax' => 4 ],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
IntegerDef::PARAM_MIN => '1โโ2',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '1',
],
],
@@ -302,9 +295,7 @@ class IntegerDefTest extends TypeDefTestCase {
[ IntegerDef::PARAM_MAX => 2, IntegerDef::PARAM_MAX2 => 4 ],
[ 'min' => null, 'max' => 2, 'highmax' => 4 ],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
IntegerDef::PARAM_MIN => '1โโ4',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '1',
],
[ 'useHighLimits' => true ],
@@ -313,9 +304,7 @@ class IntegerDefTest extends TypeDefTestCase {
[ IntegerDef::PARAM_MIN => 0, IntegerDef::PARAM_MAX => 2 ],
[ 'min' => 0, 'max' => 2 ],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
IntegerDef::PARAM_MIN => '102',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '1',
],
],
@@ -323,9 +312,7 @@ class IntegerDefTest extends TypeDefTestCase {
[ IntegerDef::PARAM_MIN => 0, IntegerDef::PARAM_MAX => 2, IntegerDef::PARAM_MAX2 => 4 ],
[ 'min' => 0, 'max' => 2, 'highmax' => 4 ],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
IntegerDef::PARAM_MIN => '102',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '1',
],
],
@@ -336,9 +323,7 @@ class IntegerDefTest extends TypeDefTestCase {
],
[ 'min' => 0, 'max' => 2, 'highmax' => 4 ],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
IntegerDef::PARAM_MIN => '204',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '2',
],
[ 'useHighLimits' => true ],
diff --git a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/LimitDefTest.php b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/LimitDefTest.php
index fab3dd7fa3d..6ac9b95f43a 100644
--- a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/LimitDefTest.php
+++ b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/LimitDefTest.php
@@ -175,9 +175,7 @@ class LimitDefTest extends TypeDefTestCase {
[],
[ 'min' => 0, 'max' => null ],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
LimitDef::PARAM_MIN => '10โ',
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '1',
],
],
diff --git a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/PresenceBooleanDefTest.php b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/PresenceBooleanDefTest.php
index c9d2c617bd0..61589c8b3e0 100644
--- a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/PresenceBooleanDefTest.php
+++ b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/PresenceBooleanDefTest.php
@@ -135,7 +135,6 @@ class PresenceBooleanDefTest extends TypeDefTestCase {
[],
[ 'default' => null ],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '1',
ParamValidator::PARAM_DEFAULT => null,
],
diff --git a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/StringDefTest.php b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/StringDefTest.php
index 5376e9207b7..603e3dd5dfc 100644
--- a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/StringDefTest.php
+++ b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/StringDefTest.php
@@ -153,9 +153,7 @@ class StringDefTest extends TypeDefTestCase {
[
'issues' => [
'X',
- // phpcs:ignore Generic.Files.LineLength
'PARAM_REQUIRED is set, allowEmptyWhenRequired is not set, and PARAM_MAX_BYTES is 0. That\'s impossible to satisfy.',
- // phpcs:ignore Generic.Files.LineLength
'PARAM_REQUIRED is set, allowEmptyWhenRequired is not set, and PARAM_MAX_CHARS is 0. That\'s impossible to satisfy.',
],
'allowedKeys' => $keys,
@@ -208,9 +206,7 @@ class StringDefTest extends TypeDefTestCase {
],
[ 'maxbytes' => 4, 'maxchars' => 2 ],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
StringDef::PARAM_MAX_BYTES => '4',
- // phpcs:ignore Generic.Files.LineLength.TooLong
StringDef::PARAM_MAX_CHARS => '2',
],
],
diff --git a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/TimestampDefTest.php b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/TimestampDefTest.php
index 0c7cbac94ee..ef5f39653bf 100644
--- a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/TimestampDefTest.php
+++ b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/TimestampDefTest.php
@@ -193,7 +193,6 @@ class TimestampDefTest extends TypeDefTestCase {
[],
[],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '1',
],
],
@@ -201,7 +200,6 @@ class TimestampDefTest extends TypeDefTestCase {
[ ParamValidator::PARAM_ISMULTI => true ],
[],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '2',
],
],
diff --git a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/UploadDefTest.php b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/UploadDefTest.php
index 11a9659ea49..2ba571405a8 100644
--- a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/UploadDefTest.php
+++ b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDef/UploadDefTest.php
@@ -253,7 +253,6 @@ class UploadDefTest extends TypeDefTestCase {
[],
[],
[
- // phpcs:ignore Generic.Files.LineLength.TooLong
ParamValidator::PARAM_TYPE => '',
],
],
diff --git a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDefTest.php b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDefTest.php
index fbd2a510191..2bbaeb9a0bc 100644
--- a/tests/phpunit/unit/includes/libs/ParamValidator/TypeDefTest.php
+++ b/tests/phpunit/unit/includes/libs/ParamValidator/TypeDefTest.php
@@ -74,17 +74,14 @@ class TypeDefTest extends \PHPUnit\Framework\TestCase {
public static function provideFailureMessage() {
return [
'Basic' => [
- // phpcs:ignore Generic.Files.LineLength.TooLong
'',
'foobar',
],
'With data' => [
- // phpcs:ignore Generic.Files.LineLength.TooLong
'{"x":123}',
'foobar', [ 'x' => 123 ]
],
'With suffix' => [
- // phpcs:ignore Generic.Files.LineLength.TooLong
'[]',
'foobar', [], 'baz'
],
@@ -139,12 +136,10 @@ class TypeDefTest extends \PHPUnit\Framework\TestCase {
public static function provideFailure() {
return [
'Basic' => [
- // phpcs:ignore Generic.Files.LineLength.TooLong
'test1234',
'foobar', 'test', 1234, [], []
],
'DataMessageValue' => [
- // phpcs:ignore Generic.Files.LineLength.TooLong
'testXXXabpt{"data":"!!!"}',
DataMessageValue::new( 'XXX-msg', [ 'a', 'b' ], 'foobar', [ 'data' => '!!!' ] )
->plaintextParams( 'pt' ),
diff --git a/tests/phpunit/unit/includes/libs/XmlTypeCheckTest.php b/tests/phpunit/unit/includes/libs/XmlTypeCheckTest.php
index 079f24a4f80..8f7bf4f0f2b 100644
--- a/tests/phpunit/unit/includes/libs/XmlTypeCheckTest.php
+++ b/tests/phpunit/unit/includes/libs/XmlTypeCheckTest.php
@@ -11,7 +11,6 @@ class XmlTypeCheckTest extends PHPUnit\Framework\TestCase {
private const WELL_FORMED_XML = "";
private const MAL_FORMED_XML = "";
- // phpcs:ignore Generic.Files.LineLength
private const XML_WITH_PIH = '';
/**
diff --git a/tests/phpunit/unit/includes/libs/http/SetCookieCompatTest.php b/tests/phpunit/unit/includes/libs/http/SetCookieCompatTest.php
index a2ca2adfab1..90d98a18feb 100644
--- a/tests/phpunit/unit/includes/libs/http/SetCookieCompatTest.php
+++ b/tests/phpunit/unit/includes/libs/http/SetCookieCompatTest.php
@@ -11,7 +11,6 @@ class SetCookieCompatTest extends TestCase {
public static function provideSetCookieEmulated() {
// Expected values are all copied from PHP 7.4
- // phpcs:disable Generic.Files.LineLength.TooLong
return [
'unrecognised key' => [
true, 'a', '',
diff --git a/tests/phpunit/unit/includes/libs/rdbms/database/DatabaseSQLTest.php b/tests/phpunit/unit/includes/libs/rdbms/database/DatabaseSQLTest.php
index 06364f65e2f..38bc9db2d14 100644
--- a/tests/phpunit/unit/includes/libs/rdbms/database/DatabaseSQLTest.php
+++ b/tests/phpunit/unit/includes/libs/rdbms/database/DatabaseSQLTest.php
@@ -1273,7 +1273,6 @@ class DatabaseSQLTest extends PHPUnit\Framework\TestCase {
}
public static function provideUnionConditionPermutations() {
- // phpcs:disable Generic.Files.LineLength
return [
[
[
@@ -1724,21 +1723,18 @@ class DatabaseSQLTest extends PHPUnit\Framework\TestCase {
$this->database->startAtomic( __METHOD__, IDatabase::ATOMIC_CANCELABLE );
$this->database->endAtomic( __METHOD__ );
$this->database->commit( __METHOD__ );
- // phpcs:ignore Generic.Files.LineLength
$this->assertLastSql( 'BEGIN; SAVEPOINT wikimedia_rdbms_atomic1; RELEASE SAVEPOINT wikimedia_rdbms_atomic1; COMMIT' );
$this->database->begin( __METHOD__ );
$this->database->startAtomic( __METHOD__, IDatabase::ATOMIC_CANCELABLE );
$this->database->cancelAtomic( __METHOD__ );
$this->database->commit( __METHOD__ );
- // phpcs:ignore Generic.Files.LineLength
$this->assertLastSql( 'BEGIN; SAVEPOINT wikimedia_rdbms_atomic1; ROLLBACK TO SAVEPOINT wikimedia_rdbms_atomic1; COMMIT' );
$this->database->startAtomic( __METHOD__, IDatabase::ATOMIC_CANCELABLE );
$this->database->startAtomic( __METHOD__, IDatabase::ATOMIC_CANCELABLE );
$this->database->cancelAtomic( __METHOD__ );
$this->database->endAtomic( __METHOD__ );
- // phpcs:ignore Generic.Files.LineLength
$this->assertLastSql( 'BEGIN; SAVEPOINT wikimedia_rdbms_atomic1; ROLLBACK TO SAVEPOINT wikimedia_rdbms_atomic1; COMMIT' );
$noOpCallack = static function () {
@@ -1753,7 +1749,6 @@ class DatabaseSQLTest extends PHPUnit\Framework\TestCase {
$this->database->begin( __METHOD__ );
$this->database->doAtomicSection( __METHOD__, $noOpCallack, IDatabase::ATOMIC_CANCELABLE );
$this->database->rollback( __METHOD__ );
- // phpcs:ignore Generic.Files.LineLength
$this->assertLastSql( 'BEGIN; SAVEPOINT wikimedia_rdbms_atomic1; RELEASE SAVEPOINT wikimedia_rdbms_atomic1; ROLLBACK' );
$fname = __METHOD__;
@@ -1954,7 +1949,6 @@ class DatabaseSQLTest extends PHPUnit\Framework\TestCase {
$this->assertSame( 'Test exception', $ex->getMessage() );
}
$this->database->commit( __METHOD__ );
- // phpcs:ignore Generic.Files.LineLength
$this->assertLastSql( 'BEGIN; SAVEPOINT wikimedia_rdbms_atomic1; ROLLBACK TO SAVEPOINT wikimedia_rdbms_atomic1; COMMIT' );
$this->database->begin( __METHOD__ );
@@ -2033,7 +2027,6 @@ class DatabaseSQLTest extends PHPUnit\Framework\TestCase {
$this->assertNull( $callback2Called );
$this->assertEquals( IDatabase::TRIGGER_ROLLBACK, $callback3Called );
$this->assertSame( 1, $callback4Called );
- // phpcs:ignore Generic.Files.LineLength
$this->assertLastSql( 'BEGIN; SAVEPOINT wikimedia_rdbms_atomic1; ROLLBACK TO SAVEPOINT wikimedia_rdbms_atomic1; SELECT 4; COMMIT; SELECT 3' );
$callback1Called = null;
@@ -2054,7 +2047,6 @@ class DatabaseSQLTest extends PHPUnit\Framework\TestCase {
$this->assertNull( $callback2Called );
$this->assertEquals( IDatabase::TRIGGER_ROLLBACK, $callback3Called );
$this->assertSame( 1, $callback4Called );
- // phpcs:ignore Generic.Files.LineLength
$this->assertLastSql( 'BEGIN; SAVEPOINT wikimedia_rdbms_atomic1; SAVEPOINT wikimedia_rdbms_atomic2; RELEASE SAVEPOINT wikimedia_rdbms_atomic2; ROLLBACK TO SAVEPOINT wikimedia_rdbms_atomic1; SELECT 4; COMMIT; SELECT 3' );
$callback1Called = null;
@@ -2113,7 +2105,6 @@ class DatabaseSQLTest extends PHPUnit\Framework\TestCase {
$this->database->cancelAtomic( __METHOD__ . '_inner' );
$this->database->cancelAtomic( __METHOD__ );
$this->database->endAtomic( __METHOD__ . '_outer' );
- // phpcs:ignore Generic.Files.LineLength
$this->assertLastSql( 'BEGIN; SAVEPOINT wikimedia_rdbms_atomic1; SAVEPOINT wikimedia_rdbms_atomic2; ROLLBACK TO SAVEPOINT wikimedia_rdbms_atomic2; SELECT 4; ROLLBACK TO SAVEPOINT wikimedia_rdbms_atomic1; SELECT 5; COMMIT' );
$this->assertSame( 1, $callback4Called );
$this->assertSame( 1, $callback5Called );
@@ -2128,7 +2119,6 @@ class DatabaseSQLTest extends PHPUnit\Framework\TestCase {
$this->database->endAtomic( __METHOD__ . '_inner' );
$this->database->cancelAtomic( __METHOD__ );
$this->database->endAtomic( __METHOD__ . '_outer' );
- // phpcs:ignore Generic.Files.LineLength
$this->assertLastSql( 'BEGIN; SAVEPOINT wikimedia_rdbms_atomic1; SAVEPOINT wikimedia_rdbms_atomic2; RELEASE SAVEPOINT wikimedia_rdbms_atomic2; ROLLBACK TO SAVEPOINT wikimedia_rdbms_atomic1; SELECT 5; SELECT 4; COMMIT' );
$this->assertSame( 1, $callback4Called );
$this->assertSame( 1, $callback5Called );
@@ -2142,7 +2132,6 @@ class DatabaseSQLTest extends PHPUnit\Framework\TestCase {
$this->database->onAtomicSectionCancel( $callback4, __METHOD__ );
$this->database->cancelAtomic( __METHOD__, $sectionId );
$this->database->endAtomic( __METHOD__ . '_outer' );
- // phpcs:ignore Generic.Files.LineLength
$this->assertLastSql( 'BEGIN; SAVEPOINT wikimedia_rdbms_atomic1; SAVEPOINT wikimedia_rdbms_atomic2; ROLLBACK TO SAVEPOINT wikimedia_rdbms_atomic1; SELECT 5; SELECT 4; COMMIT' );
$this->assertSame( 1, $callback4Called );
$this->assertSame( 1, $callback5Called );
@@ -2184,7 +2173,6 @@ class DatabaseSQLTest extends PHPUnit\Framework\TestCase {
$this->database->query( 'SELECT 1', __METHOD__ );
$this->database->endAtomic( __METHOD__ );
$this->database->commit( __METHOD__, IDatabase::FLUSHING_ALL_PEERS );
- // phpcs:ignore Generic.Files.LineLength
$this->assertLastSql( 'BEGIN; SAVEPOINT wikimedia_rdbms_atomic1; SELECT 1; RELEASE SAVEPOINT wikimedia_rdbms_atomic1; COMMIT' );
}
@@ -2308,7 +2296,6 @@ class DatabaseSQLTest extends PHPUnit\Framework\TestCase {
$this->database->delete( 'y', [ 'field' => 1 ], __METHOD__ );
$this->database->endAtomic( __METHOD__ );
$this->database->commit( __METHOD__ );
- // phpcs:ignore Generic.Files.LineLength
$this->assertLastSql( 'BEGIN; SAVEPOINT wikimedia_rdbms_atomic1; UPDATE y SET a = 1 WHERE field = 1; ROLLBACK TO SAVEPOINT wikimedia_rdbms_atomic1; DELETE FROM y WHERE field = 1; COMMIT' );
$this->assertSame( 0, $this->database->trxLevel(), 'Use after rollback()' );
diff --git a/tests/phpunit/unit/includes/libs/rdbms/querybuilder/SelectQueryBuilderTest.php b/tests/phpunit/unit/includes/libs/rdbms/querybuilder/SelectQueryBuilderTest.php
index d834cebe6ba..0125029e2dc 100644
--- a/tests/phpunit/unit/includes/libs/rdbms/querybuilder/SelectQueryBuilderTest.php
+++ b/tests/phpunit/unit/includes/libs/rdbms/querybuilder/SelectQueryBuilderTest.php
@@ -502,7 +502,6 @@ class SelectQueryBuilderTest extends PHPUnit\Framework\TestCase {
public function testFetchRowCountWithField() {
$this->sqb->table( 't' )->field( 'f' )->caller( __METHOD__ );
$this->sqb->fetchRowCount();
- // phpcs:ignore Generic.Files.LineLength.TooLong
$this->assertEquals( 'SELECT COUNT(*) AS rowcount FROM (SELECT 1 FROM t WHERE (f IS NOT NULL) ) tmp_count',
$this->db->getLastSqls() );
}
@@ -525,7 +524,6 @@ class SelectQueryBuilderTest extends PHPUnit\Framework\TestCase {
$this->db->begin( __METHOD__ );
$this->sqb->lockForUpdate();
$this->db->rollback( __METHOD__ );
- // phpcs:ignore Generic.Files.LineLength.TooLong
$this->assertEquals( 'BEGIN; SELECT COUNT(*) AS rowcount FROM (SELECT 1 FROM t WHERE a = \'b\' FOR UPDATE) tmp_count; ROLLBACK',
$this->db->getLastSqls() );
}
diff --git a/tests/phpunit/unit/includes/password/Argon2PasswordTest.php b/tests/phpunit/unit/includes/password/Argon2PasswordTest.php
index 9fd507a7836..90d7bcf943f 100644
--- a/tests/phpunit/unit/includes/password/Argon2PasswordTest.php
+++ b/tests/phpunit/unit/includes/password/Argon2PasswordTest.php
@@ -5,8 +5,6 @@
* @covers Argon2Password
* @covers Password
* @covers ParameterizedPassword
- *
- * @phpcs:disable Generic.Files.LineLength
*/
class Argon2PasswordTest extends PasswordTestCase {
diff --git a/tests/phpunit/unit/includes/password/BcryptPasswordTest.php b/tests/phpunit/unit/includes/password/BcryptPasswordTest.php
index ad9116b41c5..b234b414e24 100644
--- a/tests/phpunit/unit/includes/password/BcryptPasswordTest.php
+++ b/tests/phpunit/unit/includes/password/BcryptPasswordTest.php
@@ -16,7 +16,6 @@ class BcryptPasswordTest extends PasswordTestCase {
}
public static function providePasswordTests() {
- // phpcs:disable Generic.Files.LineLength
return [
// Tests from glibc bcrypt implementation
[ true, ':bcrypt:5$CCCCCCCCCCCCCCCCCCCCC.$E5YPO9kmyuRGyh0XouQYb4YMJKvyOeW', "U*U" ],
diff --git a/tests/phpunit/unit/includes/password/EncryptedPasswordTest.php b/tests/phpunit/unit/includes/password/EncryptedPasswordTest.php
index a68753db6d3..b2ae909149a 100644
--- a/tests/phpunit/unit/includes/password/EncryptedPasswordTest.php
+++ b/tests/phpunit/unit/includes/password/EncryptedPasswordTest.php
@@ -43,7 +43,6 @@ class EncryptedPasswordTest extends PasswordTestCase {
}
public static function providePasswordTests() {
- // phpcs:disable Generic.Files.LineLength
return [
// Encrypted with secret1
[ true, ':both:aes-256-cbc:0:izBpxujqC1YbzpCB3qAzgg==:ZqHnitT1pL4YJqKqFES2KEevZYSy2LtlibW5+IMi4XKOGKGy6sE638BXyBbLQQsBtTSrt+JyzwOayKtwIfRbaQsBridx/O1JwBSai1TkGkOsYMBXnlu2Bu/EquCBj5QpjYh7p3Uq4rpiop1KQlin1BJMwnAa1PovhxjpxnYhlhkM4X5ALoGi3XM0bapN48vt', 'password' ],
@@ -61,7 +60,6 @@ class EncryptedPasswordTest extends PasswordTestCase {
* Wrong encryption key selected
*/
public function testDecryptionError() {
- // phpcs:ignore Generic.Files.LineLength
$hash = ':secret1:aes-256-cbc:0:m1LCnQVIakfYBNlr9KEgQg==:5yPTctqrzsybdgaMEag18AZYbnL37pAtXVBqmWxkjXbnNmiDH+1bHoL8lsEVTH/sJntC82kNVgE7zeiD8xUVLYF2VUnvB5+sU+aysE45/zwsCu7a22TaischMAOWrsHZ/tIgS/TnZY2d+HNyxgsEeeYf/QoL+FhmqHquK02+4SRbA5lLuj9niYy1r5CoM9cQ';
$password = $this->passwordFactory->newFromCiphertext( $hash );
$this->expectException( PasswordError::class );
@@ -69,7 +67,6 @@ class EncryptedPasswordTest extends PasswordTestCase {
}
public function testUpdate() {
- // phpcs:ignore Generic.Files.LineLength
$hash = ':both:aes-256-cbc:0:izBpxujqC1YbzpCB3qAzgg==:ZqHnitT1pL4YJqKqFES2KEevZYSy2LtlibW5+IMi4XKOGKGy6sE638BXyBbLQQsBtTSrt+JyzwOayKtwIfRbaQsBridx/O1JwBSai1TkGkOsYMBXnlu2Bu/EquCBj5QpjYh7p3Uq4rpiop1KQlin1BJMwnAa1PovhxjpxnYhlhkM4X5ALoGi3XM0bapN48vt';
$fromHash = $this->passwordFactory->newFromCiphertext( $hash );
$this->assertTrue( $fromHash->update() );
diff --git a/tests/phpunit/unit/includes/password/LayeredParameterizedPasswordTest.php b/tests/phpunit/unit/includes/password/LayeredParameterizedPasswordTest.php
index 0f848ab1ee0..2865acadd86 100644
--- a/tests/phpunit/unit/includes/password/LayeredParameterizedPasswordTest.php
+++ b/tests/phpunit/unit/includes/password/LayeredParameterizedPasswordTest.php
@@ -35,7 +35,6 @@ class LayeredParameterizedPasswordTest extends PasswordTestCase {
}
public static function providePasswordTests() {
- // phpcs:disable Generic.Files.LineLength
return [
[
true,
diff --git a/tests/phpunit/unit/includes/registration/VersionCheckerTest.php b/tests/phpunit/unit/includes/registration/VersionCheckerTest.php
index 5930d1dfaad..e19fee4f39c 100644
--- a/tests/phpunit/unit/includes/registration/VersionCheckerTest.php
+++ b/tests/phpunit/unit/includes/registration/VersionCheckerTest.php
@@ -177,7 +177,6 @@ class VersionCheckerTest extends MediaWikiUnitTestCase {
[
'incompatible' => 'FakeExtension',
'type' => 'incompatible-extensions',
- // phpcs:ignore Generic.Files.LineLength.TooLong
'msg' => 'FakeExtension is not compatible with the current installed version of FakeDependency (1.0.0), it requires: 2.0.0.',
],
],
@@ -214,7 +213,6 @@ class VersionCheckerTest extends MediaWikiUnitTestCase {
[
'missing' => 'phpMissingExtension',
'type' => 'missing-phpExtension',
- // phpcs:ignore Generic.Files.LineLength.TooLong
'msg' => 'FakeExtension requires phpMissingExtension PHP extension to be installed.',
],
],
@@ -275,7 +273,6 @@ class VersionCheckerTest extends MediaWikiUnitTestCase {
[
'missing' => 'missingAbilityWithMessage',
'type' => 'missing-ability',
- // phpcs:ignore Generic.Files.LineLength.TooLong
'msg' => 'FakeExtension requires "missingAbilityWithMessage" ability: Missing.',
],
],
diff --git a/tests/phpunit/unit/includes/resourceloader/VueComponentParserTest.php b/tests/phpunit/unit/includes/resourceloader/VueComponentParserTest.php
index 34cf8b26b37..9f04fa6b2d0 100644
--- a/tests/phpunit/unit/includes/resourceloader/VueComponentParserTest.php
+++ b/tests/phpunit/unit/includes/resourceloader/VueComponentParserTest.php
@@ -18,7 +18,6 @@ class VueComponentParserTest extends PHPUnit\Framework\TestCase {
}
public static function provideTestParse() {
- // phpcs:disable Generic.Files.LineLength
return [
[
'{{foo}}
',
diff --git a/tests/phpunit/unit/includes/tidy/RemexDriverTest.php b/tests/phpunit/unit/includes/tidy/RemexDriverTest.php
index 5dc1e571aa5..da142f2fa08 100644
--- a/tests/phpunit/unit/includes/tidy/RemexDriverTest.php
+++ b/tests/phpunit/unit/includes/tidy/RemexDriverTest.php
@@ -206,7 +206,6 @@ class RemexDriverTest extends MediaWikiUnitTestCase {
'ad
e',
'a
d
e
'
],
- // phpcs:disable Generic.Files.LineLength
[
'Complex pwrap test 6',
'ab
cde
fg',
diff --git a/tests/phpunit/unit/includes/user/UserTimeCorrectionTest.php b/tests/phpunit/unit/includes/user/UserTimeCorrectionTest.php
index 1d48fd1f197..19aca665640 100644
--- a/tests/phpunit/unit/includes/user/UserTimeCorrectionTest.php
+++ b/tests/phpunit/unit/includes/user/UserTimeCorrectionTest.php
@@ -106,7 +106,6 @@ class UserTimeCorrectionTest extends MediaWikiUnitTestCase {
public function provideDSTVariations() {
// Amsterdam observes DST. Johannesburg does not
return [
- // phpcs:disable Generic.Files.LineLength.TooLong
[ new DateTime( '2020-12-01' ), 'ZoneInfo|60|Europe/Amsterdam', 'ZoneInfo|60|Europe/Amsterdam', true ],
[ new DateTime( '2020-12-01' ), 'ZoneInfo|120|Europe/Amsterdam', 'ZoneInfo|60|Europe/Amsterdam', true ],
[ new DateTime( '2020-12-01' ), 'ZoneInfo|120|Africa/Johannesburg', 'ZoneInfo|120|Africa/Johannesburg', true ],
diff --git a/tests/phpunit/unit/includes/utils/MWCryptHashTest.php b/tests/phpunit/unit/includes/utils/MWCryptHashTest.php
index 3a9f48cbb51..58c8b16f16f 100644
--- a/tests/phpunit/unit/includes/utils/MWCryptHashTest.php
+++ b/tests/phpunit/unit/includes/utils/MWCryptHashTest.php
@@ -22,7 +22,6 @@ class MWCryptHashTest extends MediaWikiUnitTestCase {
}
$data = 'foobar';
- // phpcs:ignore Generic.Files.LineLength
$hash = '9923afaec3a86f865bb231a588f453f84e8151a2deb4109aebc6de4284be5bebcff4fab82a7e51d920237340a043736e9d13bab196006dcca0fe65314d68eab9';
$this->assertEquals(
@@ -44,7 +43,6 @@ class MWCryptHashTest extends MediaWikiUnitTestCase {
$data = 'foobar';
$key = 'secret';
- // phpcs:ignore Generic.Files.LineLength
$hash = 'ddc94177b2020e55ce2049199fd9cc6327f416ff6dc621cc34cb43d9bec61d73372b4790c0e24957f565ecaf2d42821e6303619093e99cbe14a3b9250bda5f81';
$this->assertEquals(
diff --git a/tests/qunit/QUnitTestResources.php b/tests/qunit/QUnitTestResources.php
index 70c4511d4ca..28fee500e4f 100644
--- a/tests/qunit/QUnitTestResources.php
+++ b/tests/qunit/QUnitTestResources.php
@@ -1,7 +1,5 @@
[