Require ClassMatchesFilename sniff to pass for most of tests/
authorKunal Mehta <legoktm@member.fsf.org>
Wed, 30 Jan 2019 05:47:05 +0000 (21:47 -0800)
committerKunal Mehta <legoktm@member.fsf.org>
Wed, 30 Jan 2019 07:57:12 +0000 (23:57 -0800)
commitb6b10bb58fdc396f3c659c26ed1d8588daeb66b2
treebcaefa47922953a455e5548c47a4530a22c8bb89
parenteb2771ecbe3bc819f0783b80643add4b0192f3f3
Require ClassMatchesFilename sniff to pass for most of tests/

phpunit-patch-coverage assumes that the filename matches the classname
as a performance optimization. And for most test cases, this is true. We
should enforce this with PHPCS, mostly to help developers not make
mistakes.

Test cases that have mock classes will need to ensure that the test case
class that matches the filename comes first, since that's the only class
the sniff will look at.

Tests in GlobalFunctions/ and maintenance/ are still exempted for now,
since they don't match yet.

Change-Id: Iede341504290f5ba2da1c81908069ba9d465600f
.phpcs.xml
tests/phpunit/includes/db/DatabaseSqliteTest.php
tests/phpunit/includes/deferred/SearchUpdateTest.php
tests/phpunit/includes/libs/MemoizedCallableTest.php
tests/phpunit/includes/poolcounter/PoolCounterTest.php