WordPress.org

Make WordPress Core


Ignore:
Timestamp:
04/06/2017 06:19:02 PM (3 years ago)
Author:
swissspidy
Message:

Build/Test Tools: Add assertNotFalse() method to WP_UnitTestCase and use it where appropriate.

Props peterwilsoncc.
Fixes #39219.

Merges [39919] to the 4.7 branch.

Location:
branches/4.7
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/4.7

  • branches/4.7/tests/phpunit/tests/theme/support.php

    r37313 r40388  
    9191        $this->assertFalse( current_theme_supports( 'html5' ) );
    9292        $this->assertFalse( current_theme_supports( 'html5', 'comment-form' ) );
    93         $this->assertNotSame( false, add_theme_support( 'html5' ) );
     93        $this->assertNotFalse( add_theme_support( 'html5' ) );
    9494        $this->assertTrue( current_theme_supports( 'html5' ) );
    9595        $this->assertTrue( current_theme_supports( 'html5', 'comment-form' ) );
     
    109109        $this->assertFalse( current_theme_supports( 'html5', 'comment-form' ) );
    110110        $this->assertFalse( add_theme_support( 'html5', 'comment-form' ) );
    111         $this->assertNotSame( false, add_theme_support( 'html5', array( 'comment-form' ) ) );
     111        $this->assertNotFalse( add_theme_support( 'html5', array( 'comment-form' ) ) );
    112112        $this->assertTrue( current_theme_supports( 'html5', 'comment-form' ) );
    113113
     
    118118        // It appends, rather than replaces.
    119119        $this->assertFalse( current_theme_supports( 'html5', 'comment-list' ) );
    120         $this->assertNotSame( false, add_theme_support( 'html5', array( 'comment-list' ) ) );
     120        $this->assertNotFalse( add_theme_support( 'html5', array( 'comment-list' ) ) );
    121121        $this->assertTrue( current_theme_supports( 'html5', 'comment-form' ) );
    122122        $this->assertTrue( current_theme_supports( 'html5', 'comment-list' ) );
Note: See TracChangeset for help on using the changeset viewer.