Make WordPress Core

Changeset 47332 for branches/4.1


Ignore:
Timestamp:
02/20/2020 05:44:32 PM (5 years ago)
Author:
SergeyBiryukov
Message:

Build/Test Tools: Merge some test fixes to the 4.1 branch, for consistency with other branches.

This backports [31253-31254], [31257].

See #49485.

Location:
branches/4.1
Files:
3 deleted
3 edited

Legend:

Unmodified
Added
Removed
  • branches/4.1

  • branches/4.1/tests/phpunit/tests/image/resize.php

    r30660 r47332  
    149149
    150150    /**
    151      * Try resizing a php file (bad image)
    152      * @ticket 6821
    153      */
    154     public function test_resize_bad_image() {
    155 
    156         if ( $this->editor_engine == 'WP_Image_Editor_Imagick' ) {
    157             $this->markTestSkipped( sprintf( 'Avoid GLib-GObject-CRITICAL assertion in %s', $this->editor_engine ) );
    158             return;
    159         }
    160 
    161         $image = $this->resize_helper( DIR_TESTDATA.'/export/crazy-cdata.xml', 25, 25 );
    162         $this->assertInstanceOf( 'WP_Error', $image );
    163         $this->assertEquals( 'invalid_image', $image->get_error_code() );
    164     }
    165 
    166 
    167     /**
    168151     * Function to help out the tests
    169152     */
  • branches/4.1/tests/phpunit/tests/image/resize_gd.php

    r29120 r47332  
    2323        parent::setUp();
    2424    }
     25
     26    /**
     27     * Try resizing a php file (bad image)
     28     * @ticket 6821
     29     */
     30    public function test_resize_bad_image() {
     31
     32        $image = $this->resize_helper( DIR_TESTDATA.'/export/crazy-cdata.xml', 25, 25 );
     33        $this->assertInstanceOf( 'WP_Error', $image );
     34        $this->assertEquals( 'invalid_image', $image->get_error_code() );
     35    }
     36
    2537}
Note: See TracChangeset for help on using the changeset viewer.