Changeset 28879 for trunk/tests/phpunit/tests/image/editor.php
- Timestamp:
- 06/28/2014 03:49:55 AM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/image/editor.php
r25002 r28879 53 53 $editor = wp_get_image_editor( DIR_TESTDATA . '/images/canola.jpg' ); 54 54 55 // Make quality readable56 $property = new ReflectionProperty( $editor, 'quality' );57 $property->setAccessible( true );58 59 55 // Ensure set_quality works 60 56 $this->assertTrue( $editor->set_quality( 75 ) ); 61 $this->assertEquals( 75, $ property->getValue( $editor) );57 $this->assertEquals( 75, $editor->get_quality() ); 62 58 63 59 // Ensure the quality filter works … … 65 61 add_filter( 'wp_editor_set_quality', $func ); 66 62 $this->assertTrue( $editor->set_quality( 75 ) ); 67 $this->assertEquals( 100, $property->getValue( $editor) );63 $this->assertEquals( 75, $editor->get_quality() ); 68 64 69 65 // Clean up
Note: See TracChangeset
for help on using the changeset viewer.