WordPress.org

Make WordPress Core

Changeset 40533


Ignore:
Timestamp:
04/22/2017 10:54:15 PM (21 months ago)
Author:
johnbillion
Message:

Build/Test Tools: Remove unnecessary checks and skips that should instead cause failures if they ever fail.

See #40533

Location:
trunk/tests/phpunit/tests
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/tests/functions.php

    r40522 r40533  
    6262
    6363    function test_path_is_absolute() {
    64         if ( !is_callable('path_is_absolute') )
    65             $this->markTestSkipped();
    66 
    6764        $absolute_paths = array(
    6865            '/',
     
    8279
    8380    function test_path_is_not_absolute() {
    84         if ( !is_callable('path_is_absolute') )
    85             $this->markTestSkipped();
    86 
    8781        $relative_paths = array(
    8882            '',
  • trunk/tests/phpunit/tests/image/size.php

    r30660 r40533  
    99
    1010    function test_constrain_dims_zero() {
    11         if (!is_callable('wp_constrain_dimensions'))
    12             $this->markTestSkipped('wp_constrain_dimensions() is not callable.');
    13 
    1411        // no constraint - should have no effect
    1512        $out = wp_constrain_dimensions(640, 480, 0, 0);
     
    2724
    2825    function test_constrain_dims_smaller() {
    29         if (!is_callable('wp_constrain_dimensions'))
    30             $this->markTestSkipped('wp_constrain_dimensions() is not callable.');
    31 
    3226        // image size is smaller than the constraint - no effect
    3327        $out = wp_constrain_dimensions(500, 600, 1024, 768);
     
    4236
    4337    function test_constrain_dims_equal() {
    44         if (!is_callable('wp_constrain_dimensions'))
    45             $this->markTestSkipped('wp_constrain_dimensions() is not callable.');
    46 
    4738        // image size is equal to the constraint - no effect
    4839        $out = wp_constrain_dimensions(1024, 768, 1024, 768);
     
    5748
    5849    function test_constrain_dims_larger() {
    59         if (!is_callable('wp_constrain_dimensions'))
    60             $this->markTestSkipped('wp_constrain_dimensions() is not callable.');
    61 
    6250        // image size is larger than the constraint - result should be constrained
    6351        $out = wp_constrain_dimensions(1024, 768, 500, 600);
     
    8270
    8371    function test_constrain_dims_boundary() {
    84         if (!is_callable('wp_constrain_dimensions'))
    85             $this->markTestSkipped('wp_constrain_dimensions() is not callable.');
    86 
    8772        // one dimension is larger than the constraint, one smaller - result should be constrained
    8873        $out = wp_constrain_dimensions(1024, 768, 500, 800);
Note: See TracChangeset for help on using the changeset viewer.