[wp-trac] [WordPress Trac] #26155: Tests_Image_Functions failures

WordPress Trac noreply at wordpress.org
Fri Nov 22 03:08:44 UTC 2013


#26155: Tests_Image_Functions failures
------------------------------+------------------
 Reporter:  SergeyBiryukov    |       Owner:
     Type:  defect (bug)      |      Status:  new
 Priority:  normal            |   Milestone:  3.8
Component:  Unit Tests        |     Version:
 Severity:  normal            |  Resolution:
 Keywords:  has-patch commit  |
------------------------------+------------------
Description changed by SergeyBiryukov:

Old description:

> Three image tests are failing if both fileinfo PHP extension and
> `mime_content_type()` function are missing:
> {{{
> 1) Tests_Image_Functions::test_wp_save_image_file
> Failed asserting that two strings are equal.
> --- Expected
> +++ Actual
> @@ @@
> -'image/jpeg'
> +''
>
> S:\home\wordpress\develop\tests\phpunit\tests\image\functions.php:144
> S:\usr\local\php5\phpunit:46
>
> 2) Tests_Image_Functions::test_mime_overrides_filename
> Failed asserting that two strings are equal.
> --- Expected
> +++ Actual
> @@ @@
> -'image/gif'
> +''
>
> S:\home\wordpress\develop\tests\phpunit\tests\image\functions.php:182
> S:\usr\local\php5\phpunit:46
>
> 3) Tests_Image_Functions::test_inferred_mime_types
> Failed asserting that two strings are equal.
> --- Expected
> +++ Actual
> @@ @@
> -'image/jpeg'
> +''
> }}}
> We should skip these tests if the extension is not loaded, like we do in
> Tests_Image_Meta:
> [source:tags/3.7.1/tests/phpunit/tests/image/meta.php#L8].

New description:

 Three image tests are failing if both fileinfo PHP extension and
 `mime_content_type()` function are missing:
 {{{
 1) Tests_Image_Functions::test_wp_save_image_file
 Failed asserting that two strings are equal.
 --- Expected
 +++ Actual
 @@ @@
 -'image/jpeg'
 +''

 S:\home\wordpress\develop\tests\phpunit\tests\image\functions.php:142
 S:\usr\local\php5\phpunit:46

 2) Tests_Image_Functions::test_mime_overrides_filename
 Failed asserting that two strings are equal.
 --- Expected
 +++ Actual
 @@ @@
 -'image/gif'
 +''

 S:\home\wordpress\develop\tests\phpunit\tests\image\functions.php:180
 S:\usr\local\php5\phpunit:46

 3) Tests_Image_Functions::test_inferred_mime_types
 Failed asserting that two strings are equal.
 --- Expected
 +++ Actual
 @@ @@
 -'image/jpeg'
 +''

 S:\home\wordpress\develop\tests\phpunit\tests\image\functions.php:225
 }}}
 We should skip these tests if the extension is not loaded, like we do in
 Tests_Image_Meta:
 [source:tags/3.7.1/tests/phpunit/tests/image/meta.php#L8].

--

--
Ticket URL: <http://core.trac.wordpress.org/ticket/26155#comment:1>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list