Make WordPress Core


Ignore:
Timestamp:
07/08/2019 12:55:20 AM (5 years ago)
Author:
pento
Message:

Coding Standards: Fix the remaining issues in /tests.

All PHP files in /tests now conform to the PHP coding standards, or have exceptions appropriately marked.

Travis now also runs phpcs on the /tests directory, any future changes to these files must conform entirely to the WordPress PHP coding standards. 🎉

See #47632.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/tests/post/wpPostType.php

    r43571 r45607  
    7979        $post_type_object->add_rewrite_rules();
    8080
    81         $this->assertFalse( in_array( 'foobar', $wp->public_query_vars ) );
     81        $this->assertFalse( in_array( 'foobar', $wp->public_query_vars, true ) );
    8282    }
    8383
     
    9999
    100100        $post_type_object->add_rewrite_rules();
    101         $in_array = in_array( 'foobar', $wp->public_query_vars );
     101        $in_array = in_array( 'foobar', $wp->public_query_vars, true );
    102102
    103103        $post_type_object->remove_rewrite_rules();
    104         $in_array_after = in_array( 'foobar', $wp->public_query_vars );
     104        $in_array_after = in_array( 'foobar', $wp->public_query_vars, true );
    105105
    106106        $this->assertTrue( $in_array );
     
    129129        $rewrite_tags_after = $wp_rewrite->rewritecode;
    130130
    131         $this->assertNotFalse( array_search( "%$post_type%", $rewrite_tags ) );
    132         $this->assertFalse( array_search( "%$post_type%", $rewrite_tags_after ) );
     131        $this->assertNotFalse( array_search( "%$post_type%", $rewrite_tags, true ) );
     132        $this->assertFalse( array_search( "%$post_type%", $rewrite_tags_after, true ) );
    133133    }
    134134
Note: See TracChangeset for help on using the changeset viewer.