Make WordPress Core


Ignore:
Timestamp:
11/04/2021 03:22:47 PM (3 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/formatting/convertSmilies.php

    r51623 r52010  
    4949     * when use_smilies = 1 and not when use_smilies = 0
    5050     */
    51     function test_convert_standard_smilies( $in_txt, $converted_txt ) {
     51    public function test_convert_standard_smilies( $in_txt, $converted_txt ) {
    5252        // Standard smilies, use_smilies: ON.
    5353        update_option( 'use_smilies', 1 );
     
    9292     * Validate Custom Smilies are converted to images when use_smilies = 1
    9393     */
    94     function test_convert_custom_smilies( $in_txt, $converted_txt ) {
     94    public function test_convert_custom_smilies( $in_txt, $converted_txt ) {
    9595        global $wpsmiliestrans;
    9696
     
    300300     * @dataProvider get_spaces_around_smilies
    301301     */
    302     function test_spaces_around_smilies( $in_txt, $converted_txt ) {
     302    public function test_spaces_around_smilies( $in_txt, $converted_txt ) {
    303303        // Standard smilies, use_smilies: ON.
    304304        update_option( 'use_smilies', 1 );
Note: See TracChangeset for help on using the changeset viewer.