From: Max Semenik Date: Thu, 2 Aug 2018 01:26:41 +0000 (-0700) Subject: Add an explicit check for correct operation to ExifRotationTest X-Git-Tag: 1.34.0-rc.0~4575^2 X-Git-Url: https://git.heureux-cyclage.org/?p=lhc%2Fweb%2Fwiklou.git;a=commitdiff_plain;h=337564f6dc2058b8f3c91e01442e579dff2cfedd Add an explicit check for correct operation to ExifRotationTest Makes debugging test failures way easier than just trying to figure out what errors a couple lines below mean. Change-Id: I8e7f6b14cef0954c72b22805eee512051a2b3c86 --- diff --git a/tests/phpunit/includes/media/ExifRotationTest.php b/tests/phpunit/includes/media/ExifRotationTest.php index fff101f3a2..e64d4afadc 100644 --- a/tests/phpunit/includes/media/ExifRotationTest.php +++ b/tests/phpunit/includes/media/ExifRotationTest.php @@ -190,6 +190,11 @@ class ExifRotationTest extends MediaWikiMediaTestCase { $file = $this->dataFile( $name, $type ); $thumb = $file->transform( $params, File::RENDER_NOW | File::RENDER_FORCE ); + if ( $thumb->isError() ) { + /** @var MediaTransformError $thumb */ + $this->fail( $thumb->toText() ); + } + $this->assertEquals( $out[0], $thumb->getWidth(),