From: Stanislav Malyshev Date: Wed, 31 Aug 2011 07:10:17 +0000 (+0000) Subject: test fixes on Darwin X-Git-Tag: php-5.4.0beta1~328 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=9d52e9b15f50d9440989854a211e90eef94e8900;p=php test fixes on Darwin --- diff --git a/ext/date/tests/bug33532.phpt b/ext/date/tests/bug33532.phpt index 286ceb4cec..5c88e73acd 100644 --- a/ext/date/tests/bug33532.phpt +++ b/ext/date/tests/bug33532.phpt @@ -3,6 +3,9 @@ Bug #33532 (Different output for strftime() and date()) --INI-- error_reporting=2047 date.timezone=UTC +--SKIPIF-- + --FILE-- @@ -21,7 +21,8 @@ echo "*** Testing gmstrftime() : usage variation ***\n"; // Initialise function arguments not being substituted (if any) $timestamp = gmmktime(8, 8, 8, 8, 8, 2008); -setlocale(LC_ALL, "en_US.utf8", "en_US"); +setlocale(LC_TIME, "POSIX"); +putenv("LC_TIME=POSIX"); date_default_timezone_set("Asia/Calcutta"); //array of values to iterate over @@ -46,13 +47,13 @@ foreach($inputs as $key =>$value) { --Preferred date and time representation-- string(2) "%c" -string(31) "Fri 08 Aug 2008 08:08:08 AM GMT" +string(24) "Fri Aug 8 08:08:08 2008" --Preferred date representation-- string(2) "%x" -string(10) "08/08/2008" +string(8) "08/08/08" --Preferred time representation-- string(2) "%X" -string(11) "08:08:08 AM" +string(8) "08:08:08" ===DONE=== diff --git a/ext/date/tests/strftime_variation22.phpt b/ext/date/tests/strftime_variation22.phpt index 151a7d2067..7b72ca51e1 100644 --- a/ext/date/tests/strftime_variation22.phpt +++ b/ext/date/tests/strftime_variation22.phpt @@ -5,8 +5,8 @@ Test strftime() function : usage variation - Checking Preferred date and time re if (strtoupper(substr(PHP_OS, 0, 3)) == 'WIN') { die("skip Test is not valid for Windows"); } -if(!setlocale(LC_ALL, "en_US.utf8", "en_US")) { - die("skip Locale en_US.utf8 or en_US is needed by test and is not available"); +if(!setlocale(LC_ALL, "POSIX")) { + die("skip Locale POSIX is needed by test and is not available"); } ?> --FILE-- @@ -20,7 +20,8 @@ if(!setlocale(LC_ALL, "en_US.utf8", "en_US")) { echo "*** Testing strftime() : usage variation ***\n"; // Initialise function arguments not being substituted (if any) -setlocale(LC_ALL, "en_US.utf8", "en_US"); +setlocale(LC_ALL, "POSIX"); +putenv("LC_ALL=POSIX"); date_default_timezone_set("Asia/Calcutta"); $timestamp = mktime(8, 8, 8, 8, 8, 2008); @@ -46,13 +47,13 @@ foreach($inputs as $key =>$value) { --Preferred date and time representation-- string(2) "%c" -string(31) "Fri 08 Aug 2008 08:08:08 AM IST" +string(24) "Fri Aug 8 08:08:08 2008" --Preferred date representation-- string(2) "%x" -string(10) "08/08/2008" +string(8) "08/08/08" --Preferred time representation-- string(2) "%X" -string(11) "08:08:08 AM" +string(8) "08:08:08" ===DONE=== diff --git a/ext/standard/tests/math/bug45712.phpt b/ext/standard/tests/math/bug45712.phpt index 3ebc94c92e..e10d0e7ec3 100644 --- a/ext/standard/tests/math/bug45712.phpt +++ b/ext/standard/tests/math/bug45712.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #45712 (NaN/INF comparison) +--XFAIL-- +Bug 45712 not fixed yet. --FILE--