minor #36688 [Form] fix tests (xabbuh)
This PR was merged into the 5.1-dev branch.
Discussion
----------
[Form] fix tests
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| Deprecations? | no
| Tickets |
| License | MIT
| Doc PR |
Commits
-------
6d0195f3cd
fix tests
This commit is contained in:
commit
ca1d4b4a93
@ -42,6 +42,11 @@ class DebugCommandTest extends TestCase
|
||||
$this->assertEquals(0, $ret, 'Returns 0 in case of success');
|
||||
$this->assertSame(<<<TXT
|
||||
|
||||
Built-in form types (Symfony\Component\Form\Extension\Core\Type)
|
||||
----------------------------------------------------------------
|
||||
|
||||
PercentType
|
||||
|
||||
Service form types
|
||||
------------------
|
||||
|
||||
|
@ -77,7 +77,7 @@ class PercentToLocalizedStringTransformerTest extends TestCase
|
||||
*/
|
||||
public function testReverseTransformWithScaleAndRoundingDisabled()
|
||||
{
|
||||
$this->expectDeprecation('Since symfony/form 5.1: Not passing a rounding mode to Symfony\Component\Form\Extension\Core\DataTransformer\PercentToLocalizedStringTransformer::__construct() is deprecated. Starting with Symfony 6.0 it will default to Symfony\Component\Form\Extension\Core\DataTransformer\PercentToLocalizedStringTransformer::ROUND_HALF_UP.');
|
||||
$this->expectDeprecation('Since symfony/form 5.1: Not passing a rounding mode to Symfony\Component\Form\Extension\Core\DataTransformer\PercentToLocalizedStringTransformer::__construct() is deprecated. Starting with Symfony 6.0 it will default to "Symfony\Component\Form\Extension\Core\DataTransformer\PercentToLocalizedStringTransformer::ROUND_HALF_UP".');
|
||||
|
||||
$transformer = new PercentToLocalizedStringTransformer(2, PercentToLocalizedStringTransformer::FRACTIONAL);
|
||||
|
||||
|
@ -39,7 +39,7 @@ class PercentTypeTest extends TypeTestCase
|
||||
*/
|
||||
public function testSubmitWithoutRoundingMode()
|
||||
{
|
||||
$this->expectDeprecation('Since symfony/form 5.1: Not configuring the "rounding_mode" option is deprecated. It will default to Symfony\Component\Form\Extension\Core\DataTransformer\PercentToLocalizedStringTransformer::ROUND_HALF_UP in Symfony 6.0.');
|
||||
$this->expectDeprecation('Since symfony/form 5.1: Not configuring the "rounding_mode" option is deprecated. It will default to "Symfony\Component\Form\Extension\Core\DataTransformer\PercentToLocalizedStringTransformer::ROUND_HALF_UP" in Symfony 6.0.');
|
||||
|
||||
$form = $this->factory->create(self::TESTED_TYPE, null, [
|
||||
'scale' => 2,
|
||||
@ -55,7 +55,7 @@ class PercentTypeTest extends TypeTestCase
|
||||
*/
|
||||
public function testSubmitWithNullRoundingMode()
|
||||
{
|
||||
$this->expectDeprecation('Since symfony/form 5.1: Not configuring the "rounding_mode" option is deprecated. It will default to Symfony\Component\Form\Extension\Core\DataTransformer\PercentToLocalizedStringTransformer::ROUND_HALF_UP in Symfony 6.0.');
|
||||
$this->expectDeprecation('Since symfony/form 5.1: Not configuring the "rounding_mode" option is deprecated. It will default to "Symfony\Component\Form\Extension\Core\DataTransformer\PercentToLocalizedStringTransformer::ROUND_HALF_UP" in Symfony 6.0.');
|
||||
|
||||
$form = $this->factory->create(self::TESTED_TYPE, null, [
|
||||
'rounding_mode' => null,
|
||||
|
Reference in New Issue
Block a user