8000 [ci] Testing with UTC hides bugs · symfony/symfony@05c5880 · GitHub
[go: up one dir, main page]

Skip to content

Commit 05c5880

Browse files
[ci] Testing with UTC hides bugs
1 parent ef40651 commit 05c5880

File tree

3 files changed

+3
-4
lines changed

3 files changed

+3
-4
lines changed

.travis.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ before_install:
4747
# A sigchild-enabled-PHP is used to test the Process component on the lowest PHP matrix line
4848
- if [[ ! $deps && $PHP = ${MIN_PHP%.*} && ! -d php-$MIN_PHP/sapi ]]; then wget http://museum.php.net/php5/php-$MIN_PHP.tar.bz2 -O - | tar -xj; (cd php-$MIN_PHP; ./configure --enable-sigchild --enable-pcntl; make -j2); fi
4949
- if [[ ! $PHP = hhvm* ]]; then INI_FILE=~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini; else INI_FILE=/etc/hhvm/php.ini; fi
50+
- if [[ ! $skip ]]; then echo date.timezone = Europe/Paris >> $INI_FILE; fi
5051
- if [[ ! $skip ]]; then echo memory_limit = -1 >> $INI_FILE; fi
5152
- if [[ ! $skip ]]; then echo session.gc_probability = 0 >> $INI_FILE; fi
5253
- if [[ ! $skip && $PHP = 5.* ]]; then echo extension = mongo.so >> $INI_FILE; fi

appveyor.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ install:
3333
- cd ..
3434
- copy /Y php.ini-development php.ini-min
3535
- echo max_execution_time=1200 >> php.ini-min
36-
- echo date.timezone="UTC" >> php.ini-min
36+
- echo date.timezone="America/Los_Angeles" >> php.ini-min
3737
- echo extension_dir=ext >> php.ini-min
3838
- copy /Y php.ini-min php.ini-max
3939
- echo extension=php_openssl.dll >> php.ini-max

src/Symfony/Component/Intl/Tests/DateFormatter/AbstractIntlDateFormatterTest.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -908,9 +908,7 @@ protected function getDateTime($timestamp, $timeZone)
908908
{
909909
$dateTime = new \DateTime();
910910
$dateTime->setTimestamp(null === $timestamp ? time() : $timestamp);
911-
if (null !== $timeZone) {
912-
$dateTime->setTimezone(new \DateTimeZone($timeZone));
913-
}
911+
$dateTime->setTimezone(new \DateTimeZone($timeZone ?: date_default_timezone_get()));
914912

915913
return $dateTime;
916914
}

0 commit comments

Comments
 (0)
0