diff --git a/test/File/IsCompressedTest.php b/test/File/IsCompressedTest.php index 690fd4eea..dd0e71c2c 100644 --- a/test/File/IsCompressedTest.php +++ b/test/File/IsCompressedTest.php @@ -33,6 +33,11 @@ protected function getMagicMime() return __DIR__ . '/_files/magic.lte.5.3.10.mime'; } + // Ubuntu has backported the changes in 12.04 to PHP 5.3.10. + if (strpos(PHP_VERSION, 'ubuntu') !== false && version_compare(PHP_VERSION, '5.3.10', '>=')) { + return __DIR__ . '/_files/magic.lte.5.3.10.mime'; + } + return __DIR__ . '/_files/magic.mime'; } diff --git a/test/File/IsImageTest.php b/test/File/IsImageTest.php index e7bcea6ec..2ffa7552c 100644 --- a/test/File/IsImageTest.php +++ b/test/File/IsImageTest.php @@ -31,6 +31,11 @@ protected function getMagicMime() return __DIR__ . '/_files/magic.lte.5.3.10.mime'; } + // Ubuntu has backported the changes in 12.04 to PHP 5.3.10. + if (strpos(PHP_VERSION, 'ubuntu') !== false && version_compare(PHP_VERSION, '5.3.10', '>=')) { + return __DIR__ . '/_files/magic.lte.5.3.10.mime'; + } + return __DIR__ . '/_files/magic.mime'; }