From 9d52e9b15f50d9440989854a211e90eef94e8900 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Wed, 31 Aug 2011 07:10:17 +0000 Subject: [PATCH] test fixes on Darwin --- ext/date/tests/bug33532.phpt | 4 + ext/date/tests/gmstrftime_variation22.phpt | 13 ++- ext/date/tests/strftime_variation22.phpt | 13 ++- ext/standard/tests/math/bug45712.phpt | 2 + .../tests/strings/nl_langinfo_variation1.phpt | 104 +++--------------- ext/standard/tests/strings/strtolower.phpt | Bin 5049 -> 3889 bytes ext/standard/tests/strings/strtoupper1.phpt | Bin 5060 -> 3900 bytes 7 files changed, 34 insertions(+), 102 deletions(-) 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-- @x@=>zuETv_3xLz-u^ni{`cEIZ_jnT{Q2RsuB@Bl#@ZAc z>#n%79*PHRSM01qaj>3>Cu=Dd%M`|Pg|k8ttW+ec6vaAQ)vQqrCXih*f$W9}WE&=s z-7$gefeB3@gOaFrN)y#V2~KiRkpBpVv-)V{ZK?~G7El?k{K>efz>O~9GMhnzV3)Ddi)JY4}MGMqT3)I61G}n`n zXl{%|voQkAoe^jrj6kz90?ok)G*3pLS&Tqqj6mazKog8WlZ-%9j6l=88;R!i^Y7o@ F{13j~6TScd diff --git a/ext/standard/tests/strings/strtoupper1.phpt b/ext/standard/tests/strings/strtoupper1.phpt index 2890c02ccdae7924e74937a526a8381f91c04efd..b83a8a3a5d4476fe05efc36956fca7622627a916 100644 GIT binary patch delta 38 qcmX@2zDI6D5)-qbk;UXpCOIH&zPXF3kOd^LnTfrdWizk9c4h$A^9oo1 delta 1238 zcmXZYJ!(~96op~928HDu!a)Lt+j#!Zw~03+vDv>E2#Rq4r_;jHi3k@vODAM&WwNk) ziw*l>{kr`9`iC8^_5Qvam$mcv`tZ3s9*^%nyt+YseCV#P?oRzpcXjvnG%m~e%i+_- zi~rZ>zt6v2?5*!kw_WSe2F8FkGDftCF`>KV>C2j2%0h!%@~H} z3`Yw_pzX;@v|<#5An73l$p9fpMhHPNK?sr=LXa#Ff@FmdBpZYvX%K=$AOwj*2oi(% z{`6HGLXiZ7AV~;8Qc!}lhZ3X%lpr0U1nC4NNM|TPxS=PR5d-{73c z8=N2)I6Y3 zNl-Q