aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--tests/Wallabag/CoreBundle/Controller/EntryControllerTest.php4
-rw-r--r--var/SymfonyRequirements.php13
2 files changed, 3 insertions, 14 deletions
diff --git a/tests/Wallabag/CoreBundle/Controller/EntryControllerTest.php b/tests/Wallabag/CoreBundle/Controller/EntryControllerTest.php
index a436be79..6721b2e4 100644
--- a/tests/Wallabag/CoreBundle/Controller/EntryControllerTest.php
+++ b/tests/Wallabag/CoreBundle/Controller/EntryControllerTest.php
@@ -1325,10 +1325,6 @@ class EntryControllerTest extends WallabagCoreTestCase
1325 'http://www.hao123.com/shequ?__noscript__-=1', 1325 'http://www.hao123.com/shequ?__noscript__-=1',
1326 'zh_CN', 1326 'zh_CN',
1327 ], 1327 ],
1328 'de_AT' => [
1329 'https://buy.garmin.com/de-AT/AT/catalog/product/compareResult.ep?compareProduct=112885&compareProduct=36728',
1330 'de_AT',
1331 ],
1332 'ru_RU' => [ 1328 'ru_RU' => [
1333 'http://netler.ru/ikt/windows-error-reporting.htm', 1329 'http://netler.ru/ikt/windows-error-reporting.htm',
1334 'ru_RU', 1330 'ru_RU',
diff --git a/var/SymfonyRequirements.php b/var/SymfonyRequirements.php
index 3b14a402..4a1fcc62 100644
--- a/var/SymfonyRequirements.php
+++ b/var/SymfonyRequirements.php
@@ -389,7 +389,7 @@ class SymfonyRequirements extends RequirementCollection
389 { 389 {
390 /* mandatory requirements follow */ 390 /* mandatory requirements follow */
391 391
392 $installedPhpVersion = phpversion(); 392 $installedPhpVersion = PHP_VERSION;
393 $requiredPhpVersion = $this->getPhpRequiredVersion(); 393 $requiredPhpVersion = $this->getPhpRequiredVersion();
394 394
395 $this->addRecommendation( 395 $this->addRecommendation(
@@ -448,15 +448,8 @@ class SymfonyRequirements extends RequirementCollection
448 } 448 }
449 449
450 if (false !== $requiredPhpVersion && version_compare($installedPhpVersion, $requiredPhpVersion, '>=')) { 450 if (false !== $requiredPhpVersion && version_compare($installedPhpVersion, $requiredPhpVersion, '>=')) {
451 $timezones = array();
452 foreach (DateTimeZone::listAbbreviations() as $abbreviations) {
453 foreach ($abbreviations as $abbreviation) {
454 $timezones[$abbreviation['timezone_id']] = true;
455 }
456 }
457
458 $this->addRequirement( 451 $this->addRequirement(
459 isset($timezones[@date_default_timezone_get()]), 452 in_array(@date_default_timezone_get(), DateTimeZone::listIdentifiers(), true),
460 sprintf('Configured default timezone "%s" must be supported by your installation of PHP', @date_default_timezone_get()), 453 sprintf('Configured default timezone "%s" must be supported by your installation of PHP', @date_default_timezone_get()),
461 'Your default timezone is not supported by PHP. Check for typos in your <strong>php.ini</strong> file and have a look at the list of deprecated timezones at <a href="http://php.net/manual/en/timezones.others.php">http://php.net/manual/en/timezones.others.php</a>.' 454 'Your default timezone is not supported by PHP. Check for typos in your <strong>php.ini</strong> file and have a look at the list of deprecated timezones at <a href="http://php.net/manual/en/timezones.others.php">http://php.net/manual/en/timezones.others.php</a>.'
462 ); 455 );
@@ -731,7 +724,7 @@ class SymfonyRequirements extends RequirementCollection
731 'Install and/or enable a <strong>PHP accelerator</strong> (highly recommended).' 724 'Install and/or enable a <strong>PHP accelerator</strong> (highly recommended).'
732 ); 725 );
733 726
734 if (strtoupper(substr(PHP_OS, 0, 3)) === 'WIN') { 727 if ('WIN' === strtoupper(substr(PHP_OS, 0, 3))) {
735 $this->addRecommendation( 728 $this->addRecommendation(
736 $this->getRealpathCacheSize() >= 5 * 1024 * 1024, 729 $this->getRealpathCacheSize() >= 5 * 1024 * 1024,
737 'realpath_cache_size should be at least 5M in php.ini', 730 'realpath_cache_size should be at least 5M in php.ini',