WordPress.org

Make WordPress Core


Ignore:
Timestamp:
07/12/2014 07:08:15 AM (7 years ago)
Author:
wonderboymusic
Message:

Wouldn't it be incredible if you could run Unit Tests without all of your uploads being indiscriminately blown away and your upload folder permissions being destroyed?

The Future Is Now.

Fixes #28847.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/tests/image/editor_gd.php

    r27794 r29120  
    77 * @group wp-image-editor-gd
    88 */
     9require_once( dirname( __FILE__ ) . '/base.php' );
    910
    1011class Tests_Image_Editor_GD extends WP_Image_UnitTestCase {
     
    1920    }
    2021
    21     public function shutDown() {
     22    public function tearDown() {
    2223        $folder = DIR_TESTDATA . '/images/waffles-*.jpg';
    2324
     
    2627        }
    2728
    28         parent::shutDown();
     29        $this->remove_added_uploads();
     30
     31        parent::tearDown();
    2932    }
    3033
     
    468471
    469472        $this->assertImageAlphaAtPoint( $save_to_file, array( 0,0 ), 127 );
     473
     474        unlink( $save_to_file );
    470475    }
    471476
     
    486491
    487492        $this->assertImageAlphaAtPoint( $save_to_file, array( 0,0 ), 127 );
     493
     494        unlink( $save_to_file );
    488495    }
    489496}
Note: See TracChangeset for help on using the changeset viewer.