Skip to content

Commit

Permalink
Remove assertIsArray() with array will always evaluate to true.
Browse files Browse the repository at this point in the history
  • Loading branch information
adamsilverstein committed May 8, 2024
1 parent 2f4ca21 commit 665adde
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions tests/plugins/webp-uploads/helper-tests.php
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,6 @@ public function it_should_return_empty_array_when_filter_returns_empty_array() {

$transforms = webp_uploads_get_upload_image_mime_transforms();

$this->assertIsArray( $transforms );
$this->assertSame( array(), $transforms );
}

Expand Down Expand Up @@ -404,7 +403,6 @@ public function it_should_return_default_transforms_when_filter_returns_non_arra

$transforms = webp_uploads_get_upload_image_mime_transforms();

$this->assertIsArray( $transforms );
$this->assertSame( $default_transforms, $transforms );
}

Expand All @@ -423,7 +421,6 @@ static function () {

$transforms = webp_uploads_get_upload_image_mime_transforms();

$this->assertIsArray( $transforms );
$this->assertSame( array( 'image/jpeg' => array( 'image/jpeg' ) ), $transforms );
}

Expand All @@ -442,7 +439,6 @@ static function () {

$transforms = webp_uploads_get_upload_image_mime_transforms();

$this->assertIsArray( $transforms );
$this->assertSame( array( 'image/jpeg' => array( 'image/jpeg', 'image/webp' ) ), $transforms );
}

Expand All @@ -460,8 +456,6 @@ public function it_should_return_jpeg_and_webp_transforms_when_option_generate_w

$transforms = webp_uploads_get_upload_image_mime_transforms();

$this->assertIsArray( $transforms );

// The returned value depends on whether the server supports AVIF.
if ( webp_uploads_mime_type_supported( 'image/avif' ) ) {
$this->assertSame(
Expand Down

0 comments on commit 665adde

Please sign in to comment.