Make WordPress Core


Ignore:
Timestamp:
11/29/2022 12:32:37 PM (19 months ago)
Author:
SergeyBiryukov
Message:

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

Adds a public visibility to test fixtures, tests, data providers, and callbacks methods. This continues the previous efforts to make sure visibility is declared on all methods.

Note: This will be enforced by WPCS 3.0.0.

Follow-up to [51919], [52009], [52010].

Props jrf.
See #56791.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/tests/block-supports/layout.php

    r53916 r54889  
    3333    private $orig_theme_dir;
    3434
    35     function set_up() {
     35    public function set_up() {
    3636        parent::set_up();
    3737        $this->theme_root     = realpath( DIR_TESTDATA . '/themedir1' );
     
    5151    }
    5252
    53     function tear_down() {
     53    public function tear_down() {
    5454        $GLOBALS['wp_theme_directories'] = $this->orig_theme_dir;
    5555
     
    6464    }
    6565
    66     function filter_set_theme_root() {
     66    public function filter_set_theme_root() {
    6767        return $this->theme_root;
    6868    }
     
    7171     * @ticket 55505
    7272     */
    73     function test_outer_container_not_restored_for_non_aligned_image_block_with_non_themejson_theme() {
     73    public function test_outer_container_not_restored_for_non_aligned_image_block_with_non_themejson_theme() {
    7474        // The "default" theme doesn't have theme.json support.
    7575        switch_theme( 'default' );
     
    8787     * @ticket 55505
    8888     */
    89     function test_outer_container_restored_for_aligned_image_block_with_non_themejson_theme() {
     89    public function test_outer_container_restored_for_aligned_image_block_with_non_themejson_theme() {
    9090        // The "default" theme doesn't have theme.json support.
    9191        switch_theme( 'default' );
     
    108108     * @param string $expected         The expected block image HTML.
    109109     */
    110     function test_additional_styles_moved_to_restored_outer_container_for_aligned_image_block_with_non_themejson_theme( $block_image_html, $expected ) {
     110    public function test_additional_styles_moved_to_restored_outer_container_for_aligned_image_block_with_non_themejson_theme( $block_image_html, $expected ) {
    111111        // The "default" theme doesn't have theme.json support.
    112112        switch_theme( 'default' );
     
    161161     * @ticket 55505
    162162     */
    163     function test_outer_container_not_restored_for_aligned_image_block_with_themejson_theme() {
     163    public function test_outer_container_not_restored_for_aligned_image_block_with_themejson_theme() {
    164164        switch_theme( 'block-theme' );
    165165        $block         = array(
Note: See TracChangeset for help on using the changeset viewer.