Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions tests/phpunit/tests/image/editorImagick.php
Original file line number Diff line number Diff line change
Expand Up @@ -775,6 +775,13 @@ public function __return_eight() {
*/
public function test_resizes_are_small_for_16bit_images( $file ) {

if ( DIR_TESTDATA . '/images/png-tests/test8.png' === $file ) {
$version = Imagick::getVersion();
if ( $version['versionNumber'] >= 0x700 ) {
$this->markTestSkipped( 'ImageMagick 7 is unable to optimize grayscale images with 1-bit transparency.' );
}
}

$temp_file = DIR_TESTDATA . '/images/test-temp.png';

$imagick_image_editor = new WP_Image_Editor_Imagick( $file );
Expand Down Expand Up @@ -831,6 +838,13 @@ public static function data_resizes_are_small_for_16bit_images() {
*/
public function test_png_color_type_is_preserved_after_resize( $file_path, $expected_color_type ) {

if ( DIR_TESTDATA . '/images/png-tests/test8.png' === $file_path ) {
$version = Imagick::getVersion();
if ( $version['versionNumber'] >= 0x700 ) {
$this->markTestSkipped( 'ImageMagick 7 is unable to optimize grayscale images with 1-bit transparency.' );
}
}

$temp_file = DIR_TESTDATA . '/images/test-temp.png';

$imagick_image_editor = new WP_Image_Editor_Imagick( $file_path );
Expand Down
Loading