Skip to content

Commit 7e6e70c

Browse files
committed
Skip test if GD extension is not loaded
1 parent aa4c927 commit 7e6e70c

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

plugins/webp-uploads/tests/test-load.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1136,6 +1136,10 @@ public function test_webp_uploads_convert_palette_png_to_truecolor_hooks(): void
11361136
* @param bool $expect_changed Whether the png should be converted to truecolor.
11371137
*/
11381138
public function test_webp_uploads_convert_palette_png_to_truecolor( ?string $image_path, bool $expect_changed ): void {
1139+
if ( ! extension_loaded( 'gd' ) ) {
1140+
$this->markTestSkipped( 'GD extension is not loaded' );
1141+
}
1142+
11391143
add_filter(
11401144
'wp_image_editors',
11411145
static function () {

0 commit comments

Comments
 (0)