Make WordPress Core

Changeset 51659


Ignore:
Timestamp:
08/26/2021 01:35:16 PM (3 years ago)
Author:
hellofromTonya
Message:

Coding Standards: Update the config for WordPress.PHP.FileName in PHPCS ruleset.

The WPCS sniff already takes the test classes in the tests/phpunit/includes directory into account.

Only the test cases outside of that directory, i.e. in the tests/phpunit/tests directory need to be listed here.

Includes alphabetizing the list.

Follow-up to [42346], [45607].

Props jrf, hellofromTonya, SergeyBiryukov.
See #53359.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/phpcs.xml.dist

    r51658 r51659  
    232232        <properties>
    233233            <property name="custom_test_class_whitelist" type="array">
    234                 <!-- Test case parent classes. -->
     234                <!-- Test case parent classes in the "includes" folder, not yet accounted for in WPCS. -->
    235235                <element value="PHPUnit_Adapter_TestCase"/>
    236                 <element value="WP_UnitTestCase"/>
    237                 <element value="WP_Ajax_UnitTestCase"/>
    238                 <element value="WP_Canonical_UnitTestCase"/>
    239                 <element value="WP_Test_REST_TestCase"/>
    240                 <element value="WP_Test_REST_Controller_Testcase"/>
    241                 <element value="WP_Test_REST_Post_Type_Controller_Testcase"/>
    242                 <element value="WP_XMLRPC_UnitTestCase"/>
     236                <element value="WP_Test_XML_TestCase"/>
     237
     238                <!-- Test case parent classes outside of the "includes" folder. -->
     239                <element value="Tests_Query_Conditionals"/>
    243240                <element value="WP_Filesystem_UnitTestCase"/>
     241                <element value="WP_HTTP_UnitTestCase"/>
    244242                <element value="WP_Image_UnitTestCase"/>
    245                 <element value="WP_HTTP_UnitTestCase"/>
     243                <element value="WP_Import_UnitTestCase"/>
     244                <element value="WP_Test_Adjacent_Image_Link_TestCase"/>
    246245                <element value="WP_Tests_Image_Resize_UnitTestCase"/>
    247                 <element value="WP_Import_UnitTestCase"/>
    248                 <element value="Tests_Query_Conditionals"/>
    249                 <element value="WP_Test_XML_TestCase"/>
    250                 <element value="WP_Test_Adjacent_Image_Link_TestCase"/>
    251246
    252247                <!-- Mock classes. -->
Note: See TracChangeset for help on using the changeset viewer.