From cea34425f37fbef86f92cde05024ff1cbbc927b0 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jesper=20Hagstr=C3=B6m?= Date: Fri, 2 Jun 2017 15:29:04 +0200 Subject: [PATCH] Set timezone for intl/test/bug74298.phpt Now sets UTC as default timezone for the DateTime which otherwise uses the timezone defined in php.ini. --- ext/intl/tests/bug74298.phpt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/intl/tests/bug74298.phpt b/ext/intl/tests/bug74298.phpt index 0600a46b9c..0bfb59b48e 100644 --- a/ext/intl/tests/bug74298.phpt +++ b/ext/intl/tests/bug74298.phpt @@ -13,7 +13,7 @@ var_dump((new \IntlDateFormatter( 'UTC', \IntlDateFormatter::GREGORIAN, 'yyyy-MM-dd HH:mm:ss.SSSSSS' -))->format(new \DateTime('2017-01-01 01:02:03.123456'))); +))->format(new \DateTime('2017-01-01 01:02:03.123456', new \DateTimeZone('UTC')))); var_dump(datefmt_create( 'en-US', @@ -22,7 +22,7 @@ var_dump(datefmt_create( 'UTC', \IntlDateFormatter::GREGORIAN, 'yyyy-MM-dd HH:mm:ss.SSSSSS' -)->format(new \DateTime('2017-01-01 01:02:03.123456'))); +)->format(new \DateTime('2017-01-01 01:02:03.123456', new \DateTimeZone('UTC')))); ?> --EXPECTF-- string(26) "2017-01-01T01:02:03.123456" -- 2.50.1