You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
bug #36149 [Form] Support customized intl php.ini settings (jorrit)
This PR was merged into the 3.4 branch.
Discussion
----------
[Form] Support customized intl php.ini settings
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| Deprecations? | no
| Tickets | no
| License | MIT
| Doc PR | no
`IntlDateParser->parse()` behaves differently when `intl.error_level` and/or `intl.use_exceptions` are not 0.
This change makes sure `\IntlException` is caught when `intl.use_exceptions` is 1 and warnings thrown when `intl.error_level` is not 0 are ignored.
Commits
-------
61025d1 [Form] Support customized intl php.ini settings
Copy file name to clipboardExpand all lines: src/Symfony/Component/Form/Tests/Extension/Core/DataTransformer/DateTimeToLocalizedStringTransformerTest.php
+46Lines changed: 46 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -27,6 +27,12 @@ protected function setUp()
27
27
{
28
28
parent::setUp();
29
29
30
+
// Normalize intl. configuration settings.
31
+
if (\extension_loaded('intl')) {
32
+
$this->iniSet('intl.use_exceptions', 0);
33
+
$this->iniSet('intl.error_level', 0);
34
+
}
35
+
30
36
// Since we test against "de_AT", we need the full implementation
31
37
IntlTestHelper::requireFullIntl($this, '57.1');
32
38
@@ -334,4 +340,44 @@ public function testReverseTransformFiveDigitYearsWithTimestamp()
0 commit comments