Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 6e6c3ba

Browse files
committed
Remove void return type from test methods
1 parent ae2925d commit 6e6c3ba

File tree

6 files changed

+20
-20
lines changed

6 files changed

+20
-20
lines changed

src/Symfony/Bridge/Doctrine/Tests/ContainerAwareEventManagerTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ class MyListener
156156
public $calledByInvokeCount = 0;
157157
public $calledByEventNameCount = 0;
158158

159-
public function __invoke(): void
159+
public function __invoke()
160160
{
161161
++$this->calledByInvokeCount;
162162
}

src/Symfony/Bundle/FrameworkBundle/Tests/DependencyInjection/FrameworkExtensionTest.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1447,7 +1447,7 @@ public function provideMailer(): array
14471447
/**
14481448
* @dataProvider provideMailer
14491449
*/
1450-
public function testMailer(string $configFile, array $expectedTransports): void
1450+
public function testMailer(string $configFile, array $expectedTransports)
14511451
{
14521452
$container = $this->createContainerFromFile($configFile);
14531453

@@ -1463,14 +1463,14 @@ public function testMailer(string $configFile, array $expectedTransports): void
14631463
$this->assertEquals(new Reference('messenger.default_bus', ContainerInterface::NULL_ON_INVALID_REFERENCE), $container->getDefinition('mailer.mailer')->getArgument(1));
14641464
}
14651465

1466-
public function testMailerWithDisabledMessageBus(): void
1466+
public function testMailerWithDisabledMessageBus()
14671467
{
14681468
$container = $this->createContainerFromFile('mailer_with_disabled_message_bus');
14691469

14701470
$this->assertNull($container->getDefinition('mailer.mailer')->getArgument(1));
14711471
}
14721472

1473-
public function testMailerWithSpecificMessageBus(): void
1473+
public function testMailerWithSpecificMessageBus()
14741474
{
14751475
$container = $this->createContainerFromFile('mailer_with_specific_message_bus');
14761476

src/Symfony/Bundle/SecurityBundle/Tests/Functional/EventAliasTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424

2525
final class EventAliasTest extends AbstractWebTestCase
2626
{
27-
public function testAliasedEvents(): void
27+
public function testAliasedEvents()
2828
{
2929
$client = $this->createClient(['test_case' => 'AliasedEvents', 'root_config' => 'config.yml']);
3030
$container = $client->getContainer();

src/Symfony/Component/Console/Tests/Helper/ProgressBarTest.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -872,7 +872,7 @@ public function provideFormat(): array
872872
];
873873
}
874874

875-
public function testIterate(): void
875+
public function testIterate()
876876
{
877877
$bar = new ProgressBar($output = $this->getOutputStream(), 0, 0);
878878

@@ -887,7 +887,7 @@ public function testIterate(): void
887887
);
888888
}
889889

890-
public function testIterateUncountable(): void
890+
public function testIterateUncountable()
891891
{
892892
$bar = new ProgressBar($output = $this->getOutputStream(), 0, 0);
893893

@@ -936,7 +936,7 @@ public function testBarWidthWithMultilineFormat()
936936
putenv('COLUMNS=120');
937937
}
938938

939-
public function testMinAndMaxSecondsBetweenRedraws(): void
939+
public function testMinAndMaxSecondsBetweenRedraws()
940940
{
941941
$bar = new ProgressBar($output = $this->getOutputStream());
942942
$bar->setRedrawFrequency(1);
@@ -959,7 +959,7 @@ public function testMinAndMaxSecondsBetweenRedraws(): void
959959
);
960960
}
961961

962-
public function testMaxSecondsBetweenRedraws(): void
962+
public function testMaxSecondsBetweenRedraws()
963963
{
964964
$bar = new ProgressBar($output = $this->getOutputStream(), 0, 0);
965965
$bar->setRedrawFrequency(4); // disable step based redraws
@@ -1014,7 +1014,7 @@ public function testMinSecondsBetweenRedraws()
10141014
);
10151015
}
10161016

1017-
public function testNoWriteWhenMessageIsSame(): void
1017+
public function testNoWriteWhenMessageIsSame()
10181018
{
10191019
$bar = new ProgressBar($output = $this->getOutputStream(), 2);
10201020
$bar->start();

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

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,21 +30,21 @@ public function provideTransformations(): array
3030
/**
3131
* @dataProvider provideTransformations
3232
*/
33-
public function testTransform($from, $to): void
33+
public function testTransform($from, $to)
3434
{
3535
$transformer = new StringToFloatTransformer();
3636

3737
$this->assertSame($to, $transformer->transform($from));
3838
}
3939

40-
public function testFailIfTransformingANonString(): void
40+
public function testFailIfTransformingANonString()
4141
{
4242
$this->expectException('Symfony\Component\Form\Exception\TransformationFailedException');
4343
$transformer = new StringToFloatTransformer();
4444
$transformer->transform(1.0);
4545
}
4646

47-
public function testFailIfTransformingANonNumericString(): void
47+
public function testFailIfTransformingANonNumericString()
4848
{
4949
$this->expectException('Symfony\Component\Form\Exception\TransformationFailedException');
5050
$transformer = new StringToFloatTransformer();
@@ -70,14 +70,14 @@ public function provideReverseTransformations(): array
7070
/**
7171
* @dataProvider provideReverseTransformations
7272
*/
73-
public function testReverseTransform($from, $to, int $scale = null): void
73+
public function testReverseTransform($from, $to, int $scale = null)
7474
{
7575
$transformer = new StringToFloatTransformer($scale);
7676

7777
$this->assertSame($to, $transformer->reverseTransform($from));
7878
}
7979

80-
public function testFailIfReverseTransformingANonNumeric(): void
80+
public function testFailIfReverseTransformingANonNumeric()
8181
{
8282
$this->expectException('Symfony\Component\Form\Exception\TransformationFailedException');
8383
$transformer = new StringToFloatTransformer();

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

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -37,39 +37,39 @@ protected function tearDown(): void
3737
\Locale::setDefault($this->defaultLocale);
3838
}
3939

40-
public function testDefaultFormatting(): void
40+
public function testDefaultFormatting()
4141
{
4242
$form = $this->factory->create(static::TESTED_TYPE);
4343
$form->setData('12345.67890');
4444

4545
$this->assertSame('12345,679', $form->createView()->vars['value']);
4646
}
4747

48-
public function testDefaultFormattingWithGrouping(): void
48+
public function testDefaultFormattingWithGrouping()
4949
{
5050
$form = $this->factory->create(static::TESTED_TYPE, null, ['grouping' => true]);
5151
$form->setData('12345.67890');
5252

5353
$this->assertSame('12.345,679', $form->createView()->vars['value']);
5454
}
5555

56-
public function testDefaultFormattingWithScale(): void
56+
public function testDefaultFormattingWithScale()
5757
{
5858
$form = $this->factory->create(static::TESTED_TYPE, null, ['scale' => 2]);
5959
$form->setData('12345.67890');
6060

6161
$this->assertSame('12345,68', $form->createView()->vars['value']);
6262
}
6363

64-
public function testDefaultFormattingWithScaleFloat(): void
64+
public function testDefaultFormattingWithScaleFloat()
6565
{
6666
$form = $this->factory->create(static::TESTED_TYPE, null, ['scale' => 2]);
6767
$form->setData(12345.67890);
6868

6969
$this->assertSame('12345,68', $form->createView()->vars['value']);
7070
}
7171

72-
public function testDefaultFormattingWithScaleAndStringInput(): void
72+
public function testDefaultFormattingWithScaleAndStringInput()
7373
{
7474
$form = $this->factory->create(static::TESTED_TYPE, null, ['scale' => 2, 'input' => 'string']);
7575
$form->setData('12345.67890');

0 commit comments

Comments
 (0)