8000 minor #20551 [ci] Testing with UTC hides bugs (nicolas-grekas) · symfony/symfony@e968d0f · GitHub
[go: up one dir, main page]

Skip to content

Commit e968d0f

Browse files
minor #20551 [ci] Testing with UTC hides bugs (nicolas-grekas)
This PR was merged into the 2.7 branch. Discussion ---------- [ci] Testing with UTC hides bugs | Q | A | ------------- | --- | Branch? | 2.7 | Bug fix? | no | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | - | License | MIT | Doc PR | - As shown by #20550, we're having bugs because we don't in proper TZ conditions. Let's do Europe on Travis, and America on Windows. Commits ------- e0f9bda [ci] Testing with UTC hides bugs
2 parents 015fe87 + e0f9bda commit e968d0f

26 files changed

+72
-75
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/Form/Tests/Extension/Core/DataTransformer/IntegerToLocalizedStringTransformerTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ public function testTransformWithRounding($input, $output, $roundingMode)
8787
public function testReverseTransform()
8888
{
8989
// Since we test against "de_AT", we need the full implementation
90-
IntlTestHelper::requireFullIntl($this);
90+
IntlTestHelper::requireFullIntl($this, false);
9191

9292
\Locale::setDefault('de_AT');
9393

@@ -109,7 +109,7 @@ public function testReverseTransformEmpty()
109109
public function testReverseTransformWithGrouping()
110110
{
111111
// Since we test against "de_AT", we need the full implementation
112-
IntlTestHelper::requireFullIntl($this);
112+
IntlTestHelper::requireFullIntl($this, false);
113113

114114
\Locale::setDefault('de_AT');
115115

src/Symfony/Component/Form/Tests/Extension/Core/DataTransformer/MoneyToLocalizedStringTransformerTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ class MoneyToLocalizedStringTransformerTest extends \PHPUnit_Framework_TestCase
1919
public function testTransform()
2020
{
2121
// Since we test against "de_AT", we need the full implementation
22-
IntlTestHelper::requireFullIntl($this);
22+
IntlTestHelper::requireFullIntl($this, false);
2323

2424
\Locale::setDefault('de_AT');
2525

@@ -47,7 +47,7 @@ public function testTransformEmpty()
4747
public function testReverseTransform()
4848
{
4949
// Since we test against "de_AT", we need the full implementation
50-
IntlTestHelper::requireFullIntl($this);
50+
IntlTestHelper::requireFullIntl($this, false);
5151

5252
\Locale::setDefault('de_AT');
5353

src/Symfony/Component/Form/Tests/Extension/Core/DataTransformer/NumberToLocalizedStringTransformerTest.php

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public function provideTransformations()
4242
public function testTransform($from, $to, $locale)
4343
{
4444
// Since we test against other locales, we need the full implementation
45-
IntlTestHelper::requireFullIntl($this);
45+
IntlTestHelper::requireFullIntl($this, false);
4646

4747
\Locale::setDefault($locale);
4848

@@ -68,7 +68,7 @@ public function provideTransformationsWithGrouping()
6868
public function testTransformWithGrouping($from, $to, $locale)
6969
{
7070
// Since we test against other locales, we need the full implementation
71-
IntlTestHelper::requireFullIntl($this);
71+
IntlTestHelper::requireFullIntl($this, false);
7272

7373
\Locale::setDefault($locale);
7474

@@ -80,7 +80,7 @@ public function testTransformWithGrouping($from, $to, $locale)
8080
public function testTransformWithScale()
8181
{
8282
// Since we test against "de_AT", we need the full implementation
83-
IntlTestHelper::requireFullIntl($this);
83+
IntlTestHelper::requireFullIntl($this, false);
8484

8585
\Locale::setDefault('de_AT');
8686

@@ -185,7 +185,7 @@ public function transformWithRoundingProvider()
185185
public function testTransformWithRounding($scale, $input, $output, $roundingMode)
186186
{
187187
// Since we test against "de_AT", we need the full implementation
188-
IntlTestHelper::requireFullIntl($this);
188+
IntlTestHelper::requireFullIntl($this, false);
189189

190190
\Locale::setDefault('de_AT');
191191

@@ -197,7 +197,7 @@ public function testTransformWithRounding($scale, $input, $output, $roundingMode
197197
public function testTransformDoesNotRoundIfNoScale()
198198
{
199199
// Since we test against "de_AT", we need the full implementation
200-
IntlTestHelper::requireFullIntl($this);
200+
IntlTestHelper::requireFullIntl($this, false);
201201

202202
\Locale::setDefault('de_AT');
203203

@@ -212,7 +212,7 @@ public function testTransformDoesNotRoundIfNoScale()
212212
public function testReverseTransform($to, $from, $locale)
213213
{
214214
// Since we test against other locales, we need the full implementation
215-
IntlTestHelper::requireFullIntl($this);
215+
IntlTestHelper::requireFullIntl($this, false);
216216

217217
\Locale::setDefault($locale);
218218

@@ -227,7 +227,7 @@ public function testReverseTransform($to, $from, $locale)
227227
public function testReverseTransformWithGrouping($to, $from, $locale)
228228
{
229229
// Since we test against other locales, we need the full implementation
230-
IntlTestHelper::requireFullIntl($this);
230+
IntlTestHelper::requireFullIntl($this, false);
231231

232232
\Locale::setDefault($locale);
233233

@@ -244,7 +244,7 @@ public function testReverseTransformWithGrouping($to, $from, $locale)
244244
public function testReverseTransformWithGroupingAndFixedSpaces()
245245
{
246246
// Since we test against other locales, we need the full implementation
247-
IntlTestHelper::requireFullIntl($this);
247+
IntlTestHelper::requireFullIntl($this, false);
248248

249249
\Locale::setDefault('ru');
250250

@@ -256,7 +256,7 @@ public function testReverseTransformWithGroupingAndFixedSpaces()
256256
public function testReverseTransformWithGroupingButWithoutGroupSeparator()
257257
{
258258
// Since we test against "de_AT", we need the full implementation
259-
IntlTestHelper::requireFullIntl($this);
259+
IntlTestHelper::requireFullIntl($this, false);
260260

261261
\Locale::setDefault('de_AT');
262262

@@ -376,7 +376,7 @@ public function testReverseTransformDoesNotRoundIfNoScale()
376376
public function testDecimalSeparatorMayBeDotIfGroupingSeparatorIsNotDot()
377377
{
378378
// Since we test against other locales, we need the full implementation
379-
IntlTestHelper::requireFullIntl($this);
379+
IntlTestHelper::requireFullIntl($this, false);
380380

381381
\Locale::setDefault('fr');
382382
$transformer = new NumberToLocalizedStringTransformer(null, true);
@@ -396,7 +396,7 @@ public function testDecimalSeparatorMayBeDotIfGroupingSeparatorIsNotDot()
396396
public function testDecimalSeparatorMayNotBeDotIfGroupingSeparatorIsDot()
397397
{
398398
// Since we test against "de_AT", we need the full implementation
399-
IntlTestHelper::requireFullIntl($this);
399+
IntlTestHelper::requireFullIntl($this, false);
400400

401401
\Locale::setDefault('de_AT');
402402

@@ -411,7 +411,7 @@ public function testDecimalSeparatorMayNotBeDotIfGroupingSeparatorIsDot()
411411
public function testDecimalSeparatorMayNotBeDotIfGroupingSeparatorIsDotWithNoGroupSep()
412412
{
413413
// Since we test against "de_AT", we need the full implementation
414-
IntlTestHelper::requireFullIntl($this);
414+
IntlTestHelper::requireFullIntl($this, false);
415415

416416
\Locale::setDefault('de_AT');
417417

@@ -423,7 +423,7 @@ public function testDecimalSeparatorMayNotBeDotIfGroupingSeparatorIsDotWithNoGro
423423
public function testDecimalSeparatorMayBeDotIfGroupingSeparatorIsDotButNoGroupingUsed()
424424
{
425425
// Since we test against other locales, we need the full implementation
426-
IntlTestHelper::requireFullIntl($this);
426+
IntlTestHelper::requireFullIntl($this, false);
427427

428428
\Locale::setDefault('fr');
429429
$transformer = new NumberToLocalizedStringTransformer();
@@ -435,7 +435,7 @@ public function testDecimalSeparatorMayBeDotIfGroupingSeparatorIsDotButNoGroupin
435435
public function testDecimalSeparatorMayBeCommaIfGroupingSeparatorIsNotComma()
436436
{
437437
// Since we test against other locales, we need the full implementation
438-
IntlTestHelper::requireFullIntl($this);
438+
IntlTestHelper::requireFullIntl($this, false);
439439

440440
\Locale::setDefault('bg');
441441
$transformer = new NumberToLocalizedStringTransformer(null, true);
@@ -588,7 +588,7 @@ public function testReverseTransformDisallowsCenteredExtraCharacters()
588588
public function testReverseTransformDisallowsCenteredExtraCharactersMultibyte()
589589
{
590590
// Since we test against other locales, we need the full implementation
591-
IntlTestHelper::requireFullIntl($this);
591+
IntlTestHelper::requireFullIntl($this, false);
592592

593593
\Locale::setDefault('ru');
594594

@@ -605,7 +605,7 @@ public function testReverseTransformDisallowsCenteredExtraCharactersMultibyte()
605605
public function testReverseTransformIgnoresTrailingSpacesInExceptionMessage()
606606
{
607607
// Since we test against other locales, we need the full implementation
608-
IntlTestHelper::requireFullIntl($this);
608+
IntlTestHelper::requireFullIntl($this, false);
609609

610610
\Locale::setDefault('ru');
611611

@@ -633,7 +633,7 @@ public function testReverseTransformDisallowsTrailingExtraCharacters()
633633
public function testReverseTransformDisallowsTrailingExtraCharactersMultibyte()
634634
{
635635
// Since we test against other locales, we need the full implementation
636-
IntlTestHelper::requireFullIntl($this);
636+
IntlTestHelper::requireFullIntl($this, false);
637637

638638
\Locale::setDefault('ru');
639639

src/Symfony/Component/Form/Tests/Extension/Core/DataTransformer/PercentToLocalizedStringTransformerTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ public function testTransformWithInteger()
5353
public function testTransformWithScale()
5454
{
5555
// Since we test against "de_AT", we need the full implementation
56-
IntlTestHelper::requireFullIntl($this);
56+
IntlTestHelper::requireFullIntl($this, false);
5757

5858
\Locale::setDefault('de_AT');
5959

@@ -92,7 +92,7 @@ public function testReverseTransformWithInteger()
9292
public function testReverseTransformWithScale()
9393
{
9494
// Since we test against "de_AT", we need the full implementation
95-
IntlTestHelper::requireFullIntl($this);
95+
IntlTestHelper::requireFullIntl($this, false);
9696

9797
\Locale::setDefault('de_AT');
9898

src/Symfony/Component/Form/Tests/Extension/Core/Type/CountryTypeTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ class CountryTypeTest extends TestCase
1919
{
2020
protected function setUp()
2121
{
22-
IntlTestHelper::requireIntl($this);
22+
IntlTestHelper::requireIntl($this, false);
2323

2424
parent::setUp();
2525
}

src/Symfony/Component/Form/Tests/Extension/Core/Type/CurrencyTypeTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ class CurrencyTypeTest extends TestCase
1919
{
2020
protected function setUp()
2121
{
22-
IntlTestHelper::requireIntl($this);
22+
IntlTestHelper::requireIntl($this, false);
2323

2424
parent::setUp();
2525
}

src/Symfony/Component/Form/Tests/Extension/Core/Type/DateTypeTest.php

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ public function testSubmitFromSingleTextDateTimeWithDefaultFormat()
7070
public function testSubmitFromSingleTextDateTime()
7171
{
7272
// we test against "de_AT", so we need the full implementation
73-
IntlTestHelper::requireFullIntl($this);
73+
IntlTestHelper::requireFullIntl($this, false);
7474

7575
\Locale::setDefault('de_AT');
7676

@@ -91,7 +91,7 @@ public function testSubmitFromSingleTextDateTime()
9191
public function testSubmitFromSingleTextString()
9292
{
9393
// we test against "de_AT", so we need the full implementation
94-
IntlTestHelper::requireFullIntl($this);
94+
IntlTestHelper::requireFullIntl($this, false);
9595

9696
\Locale::setDefault('de_AT');
9797

@@ -112,7 +112,7 @@ public function testSubmitFromSingleTextString()
112112
public function testSubmitFromSingleTextTimestamp()
113113
{
114114
// we test against "de_AT", so we need the full implementation
115-
IntlTestHelper::requireFullIntl($this);
115+
IntlTestHelper::requireFullIntl($this, false);
116116

117117
\Locale::setDefault('de_AT');
118118

@@ -135,7 +135,7 @@ public function testSubmitFromSingleTextTimestamp()
135135
public function testSubmitFromSingleTextRaw()
136136
{
137137
// we test against "de_AT", so we need the full implementation
138-
IntlTestHelper::requireFullIntl($this);
138+
IntlTestHelper::requireFullIntl($this, false);
139139

140140
\Locale::setDefault('de_AT');
141141

@@ -399,7 +399,7 @@ public function testThrowExceptionIfDaysIsInvalid()
399399
public function testSetDataWithNegativeTimezoneOffsetStringInput()
400400
{
401401
// we test against "de_AT", so we need the full implementation
402-
IntlTestHelper::requireFullIntl($this);
402+
IntlTestHelper::requireFullIntl($this, false);
403403

404404
\Locale::setDefault('de_AT');
405405

@@ -421,7 +421,7 @@ public function testSetDataWithNegativeTimezoneOffsetStringInput()
421421
public function testSetDataWithNegativeTimezoneOffsetDateTimeInput()
422422
{
423423
// we test against "de_AT", so we need the full implementation
424-
IntlTestHelper::requireFullIntl($this);
424+
IntlTestHelper::requireFullIntl($this, false);
425425

426426
\Locale::setDefault('de_AT');
427427

@@ -495,7 +495,7 @@ public function testMonthsOptionShortFormat()
495495
public function testMonthsOptionLongFormat()
496496
{
497497
// we test against "de_AT", so we need the full implementation
498-
IntlTestHelper::requireFullIntl($this);
498+
IntlTestHelper::requireFullIntl($this, false);
499499

500500
\Locale::setDefault('de_AT');
501501

@@ -515,7 +515,7 @@ public function testMonthsOptionLongFormat()
515515
public function testMonthsOptionLongFormatWithDifferentTimezone()
516516
{
517517
// we test against "de_AT", so we need the full implementation
518-
IntlTestHelper::requireFullIntl($this);
518+
IntlTestHelper::requireFullIntl($this, false);
519519

520520
\Locale::setDefault('de_AT');
521521

@@ -621,7 +621,7 @@ public function testIsPartiallyFilledReturnsTrueIfChoiceAndDayEmpty()
621621
public function testPassDatePatternToView()
622622
{
623623
// we test against "de_AT", so we need the full implementation
624-
IntlTestHelper::requireFullIntl($this);
624+
IntlTestHelper::requireFullIntl($this, false);
625625

626626
\Locale::setDefault('de_AT');
627627

@@ -634,7 +634,7 @@ public function testPassDatePatternToView()
634634
public function testPassDatePatternToViewDifferentFormat()
635635
{
636636
// we test against "de_AT", so we need the full implementation
637-
IntlTestHelper::requireFullIntl($this);
637+
IntlTestHelper::requireFullIntl($this, false);
638638

639639
\Locale::setDefault('de_AT');
640640

@@ -682,7 +682,7 @@ public function testDontPassDatePatternIfText()
682682
public function testDatePatternFormatWithQuotedStrings()
683683
{
684684
// we test against "es_ES", so we need the full implementation
685-
IntlTestHelper::requireFullIntl($this);
685+
IntlTestHelper::requireFullIntl($this, false);
686686

687687
\Locale::setDefault('es_ES');
688688

src/Symfony/Component/Form/Tests/Extension/Core/Type/IntegerTypeTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ class IntegerTypeTest extends TestCase
1818
{
1919
protected function setUp()
2020
{
21-
IntlTestHelper::requireIntl($this);
21+
IntlTestHelper::requireIntl($this, false);
2222

2323
parent::setUp();
2424
}

src/Symfony/Component/Form/Tests/Extension/Core/Type/LanguageTypeTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ class LanguageTypeTest extends TestCase
1919
{
2020
protected function setUp()
2121
{
22-
IntlTestHelper::requireIntl($this);
22+
IntlTestHelper::requireIntl($this, false);
2323

2424
parent::setUp();
2525
}

src/Symfony/Component/Form/Tests/Extension/Core/Type/LocaleTypeTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ class LocaleTypeTest extends TestCase
1919
{
2020
protected function setUp()
2121
{
22-
IntlTestHelper::requireIntl($this);
22+
IntlTestHelper::requireIntl($this, false);
2323

2424
parent::setUp();
2525
}

src/Symfony/Component/Form/Tests/Extension/Core/Type/MoneyTypeTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ protected function setUp()
2020
{
2121
// we test against different locales, so we need the full
2222
// implementation
23-
IntlTestHelper::requireFullIntl($this);
23+
IntlTestHelper::requireFullIntl($this, false);
2424

2525
parent::setUp();
2626
}

src/Symfony/Component/Form/Tests/Extension/Core/Type/NumberTypeTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ protected function setUp()
2121
parent::setUp();
2222

2323
// we test against "de_DE", so we need the full implementation
24-
IntlTestHelper::requireFullIntl($this);
24+
IntlTestHelper::requireFullIntl($this, false);
2525

2626
\Locale::setDefault('de_DE');
2727
}

src/Symfony/Component/Intl/Tests/Collator/Verification/CollatorTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ class CollatorTest extends AbstractCollatorTest
2424
{
2525
protected function setUp()
2626
{
27-
IntlTestHelper::requireFullIntl($this);
27+
IntlTestHelper::requireFullIntl($this, false);
2828

2929
parent::setUp();
3030
}

0 commit comments

Comments
 (0)
0