Make WordPress Core


Ignore:
Timestamp:
11/04/2021 03:22:47 PM (4 years ago)
Author:
hellofromTonya
Message:

Coding Standards: Add visibility to methods in tests/phpunit/tests/.

Adds a public visibility to test fixtures, tests, data providers, and callbacks methods.

Adds a private visibility to helper methods within test classes.

Renames callbacks and helpers that previously started with a _ prefix. Why? For consistency and to leverage using the method visibility. Further naming standardizations is beyond the scope of this commit.

Props costdev, jrf, hellofromTonya.
Fixes #54177.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/tests/blocks/wpBlockList.php

    r51568 r52010  
    4646     * @ticket 49927
    4747     */
    48     function test_array_access() {
     48    public function test_array_access() {
    4949        $parsed_blocks = parse_blocks( '<!-- wp:example /-->' );
    5050        $context       = array();
     
    7070     * @ticket 49927
    7171     */
    72     function test_iterable() {
     72    public function test_iterable() {
    7373        $parsed_blocks = parse_blocks( '<!-- wp:example --><!-- wp:example /--><!-- /wp:example -->' );
    7474        $context       = array();
     
    102102     * @ticket 49927
    103103     */
    104     function test_countable() {
     104    public function test_countable() {
    105105        $parsed_blocks = parse_blocks( '<!-- wp:example /-->' );
    106106        $context       = array();
Note: See TracChangeset for help on using the changeset viewer.