Skip to content
This repository has been archived by the owner on Jan 8, 2020. It is now read-only.

Validator\File tests throwing errors in custom PHP 5.3.10 distributions #4877

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion tests/ZendTest/Validator/File/IsCompressedTest.php
Expand Up @@ -26,7 +26,7 @@ protected function getMagicMime()
{
// As of PHP >= 5.3.11 and >= 5.4.1 the magic database format has changed.
// http://doc.php.net/downloads/pdf/split/de/File-Information.pdf (page 11)
if (version_compare(PHP_VERSION, '5.3.10', '<=')
if (version_compare(PHP_VERSION, '5.3.11', '<')
|| (version_compare(PHP_VERSION, '5.4', '>=')
&& version_compare(PHP_VERSION, '5.4.1', '<'))
) {
Expand Down
6 changes: 4 additions & 2 deletions tests/ZendTest/Validator/File/IsImageTest.php
Expand Up @@ -26,8 +26,10 @@ protected function getMagicMime()
{
// As of PHP >= 5.3.11 and >= 5.4.1 the magic database format has changed.
// http://doc.php.net/downloads/pdf/split/de/File-Information.pdf (page 11)
if (version_compare(PHP_VERSION, '5.3.10', '<=') || (version_compare(PHP_VERSION, '5.4', '>=') &&
version_compare(PHP_VERSION, '5.4.1', '<'))) {
if (version_compare(PHP_VERSION, '5.3.11', '<')
|| (version_compare(PHP_VERSION, '5.4', '>=')
&& version_compare(PHP_VERSION, '5.4.1', '<'))
) {
return __DIR__ . '/_files/magic.lte.5.3.10.mime';
}

Expand Down