Skip to content

Commit ccb3a4c

Browse files
Merge branch '3.4' into 4.3
* 3.4: [Form] Fix inconsistencies Use Phpunit FQDN in tests comments
2 parents d4df6cf + 1c8b067 commit ccb3a4c

33 files changed

+108
-82
lines changed

src/Symfony/Bridge/Doctrine/Tests/Form/ChoiceList/DoctrineChoiceLoaderTest.php

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
use Doctrine\Common\Persistence\ObjectManager;
1515
use Doctrine\Common\Persistence\ObjectRepository;
1616
use Doctrine\ORM\Mapping\ClassMetadata;
17+
use PHPUnit\Framework\MockObject\MockObject;
1718
use PHPUnit\Framework\TestCase;
1819
use Symfony\Bridge\Doctrine\Form\ChoiceList\DoctrineChoiceLoader;
1920
use Symfony\Bridge\Doctrine\Form\ChoiceList\EntityLoaderInterface;
@@ -28,17 +29,17 @@
2829
class DoctrineChoiceLoaderTest extends TestCase
2930
{
3031
/**
31-
* @var ChoiceListFactoryInterface|\PHPUnit_Framework_MockObject_MockObject
32+
* @var ChoiceListFactoryInterface|MockObject
3233
*/
3334
private $factory;
3435

3536
/**
36-
* @var ObjectManager|\PHPUnit_Framework_MockObject_MockObject
37+
* @var ObjectManager|MockObject
3738
*/
3839
private $om;
3940

4041
/**
41-
* @var ObjectRepository|\PHPUnit_Framework_MockObject_MockObject
42+
* @var ObjectRepository|MockObject
4243
*/
4344
private $repository;
4445

@@ -48,12 +49,12 @@ class DoctrineChoiceLoaderTest extends TestCase
4849
private $class;
4950

5051
/**
51-
* @var IdReader|\PHPUnit_Framework_MockObject_MockObject
52+
* @var IdReader|MockObject
5253
*/
5354
private $idReader;
5455

5556
/**
56-
* @var EntityLoaderInterface|\PHPUnit_Framework_MockObject_MockObject
57+
* @var EntityLoaderInterface|MockObject
5758
*/
5859
private $objectLoader;
5960

src/Symfony/Bridge/Doctrine/Tests/Form/Type/EntityTypeTest.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
use Doctrine\ORM\EntityManager;
1717
use Doctrine\ORM\EntityRepository;
1818
use Doctrine\ORM\Tools\SchemaTool;
19+
use PHPUnit\Framework\MockObject\MockObject;
1920
use Symfony\Bridge\Doctrine\Form\DoctrineOrmExtension;
2021
use Symfony\Bridge\Doctrine\Form\DoctrineOrmTypeGuesser;
2122
use Symfony\Bridge\Doctrine\Form\Type\EntityType;
@@ -53,7 +54,7 @@ class EntityTypeTest extends BaseTypeTest
5354
private $em;
5455

5556
/**
56-
* @var \PHPUnit_Framework_MockObject_MockObject|ManagerRegistry
57+
* @var MockObject|ManagerRegistry
5758
*/
5859
private $emRegistry;
5960

src/Symfony/Bundle/FrameworkBundle/Tests/CacheWarmer/AnnotationsCacheWarmerTest.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
use Doctrine\Common\Annotations\AnnotationReader;
66
use Doctrine\Common\Annotations\CachedReader;
77
use Doctrine\Common\Annotations\Reader;
8+
use PHPUnit\Framework\MockObject\MockObject;
89
use Symfony\Bundle\FrameworkBundle\CacheWarmer\AnnotationsCacheWarmer;
910
use Symfony\Bundle\FrameworkBundle\Tests\TestCase;
1011
use Symfony\Component\Cache\Adapter\NullAdapter;
@@ -72,7 +73,7 @@ public function testAnnotationsCacheWarmerWithDebugEnabled()
7273
}
7374

7475
/**
75-
* @return \PHPUnit_Framework_MockObject_MockObject|Reader
76+
* @return MockObject|Reader
7677
*/
7778
private function getReadOnlyReader()
7879
{

src/Symfony/Bundle/FrameworkBundle/Tests/Command/CachePoolDeleteCommandTest.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111

1212
namespace Symfony\Bundle\FrameworkBundle\Tests\Command;
1313

14+
use PHPUnit\Framework\MockObject\MockObject;
1415
use Psr\Cache\CacheItemPoolInterface;
1516
use Symfony\Bundle\FrameworkBundle\Command\CachePoolDeleteCommand;
1617
use Symfony\Bundle\FrameworkBundle\Console\Application;
@@ -83,7 +84,7 @@ public function testCommandDeleteFailed()
8384
}
8485

8586
/**
86-
* @return \PHPUnit_Framework_MockObject_MockObject|KernelInterface
87+
* @return MockObject|KernelInterface
8788
*/
8889
private function getKernel()
8990
{

src/Symfony/Bundle/FrameworkBundle/Tests/Command/CachePruneCommandTest.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111

1212
namespace Symfony\Bundle\FrameworkBundle\Tests\Command;
1313

14+
use PHPUnit\Framework\MockObject\MockObject;
1415
use Symfony\Bundle\FrameworkBundle\Command\CachePoolPruneCommand;
1516
use Symfony\Bundle\FrameworkBundle\Console\Application;
1617
use Symfony\Bundle\FrameworkBundle\Tests\TestCase;
@@ -49,7 +50,7 @@ private function getEmptyRewindableGenerator(): RewindableGenerator
4950
}
5051

5152
/**
52-
* @return \PHPUnit_Framework_MockObject_MockObject|KernelInterface
53+
* @return MockObject|KernelInterface
5354
*/
5455
private function getKernel()
5556
{
@@ -75,7 +76,7 @@ private function getKernel()
7576
}
7677

7778
/**
78-
* @return \PHPUnit_Framework_MockObject_MockObject|PruneableInterface
79+
* @return MockObject|PruneableInterface
7980
*/
8081
private function getPruneableInterfaceMock()
8182
{

src/Symfony/Component/Cache/Tests/Adapter/ChainAdapterTest.php

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111

1212
namespace Symfony\Component\Cache\Tests\Adapter;
1313

14+
use PHPUnit\Framework\MockObject\MockObject;
1415
use Symfony\Component\Cache\Adapter\AdapterInterface;
1516
use Symfony\Component\Cache\Adapter\ArrayAdapter;
1617
use Symfony\Component\Cache\Adapter\ChainAdapter;
@@ -69,7 +70,7 @@ public function testPrune()
6970
}
7071

7172
/**
72-
* @return \PHPUnit_Framework_MockObject_MockObject|PruneableCacheInterface
73+
* @return MockObject|PruneableCacheInterface
7374
*/
7475
private function getPruneableMock()
7576
{
@@ -86,7 +87,7 @@ private function getPruneableMock()
8687
}
8788

8889
/**
89-
* @return \PHPUnit_Framework_MockObject_MockObject|PruneableCacheInterface
90+
* @return MockObject|PruneableCacheInterface
9091
*/
9192
private function getFailingPruneableMock()
9293
{
@@ -103,7 +104,7 @@ private function getFailingPruneableMock()
103104
}
104105

105106
/**
106-
* @return \PHPUnit_Framework_MockObject_MockObject|AdapterInterface
107+
* @return MockObject|AdapterInterface
107108
*/
108109
private function getNonPruneableMock()
109110
{

src/Symfony/Component/Cache/Tests/Adapter/TagAwareAdapterTest.php

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111

1212
namespace Symfony\Component\Cache\Tests\Adapter;
1313

14+
use PHPUnit\Framework\MockObject\MockObject;
1415
use Symfony\Component\Cache\Adapter\AdapterInterface;
1516
use Symfony\Component\Cache\Adapter\FilesystemAdapter;
1617
use Symfony\Component\Cache\Adapter\TagAwareAdapter;
@@ -65,7 +66,7 @@ public function testPrune()
6566
}
6667

6768
/**
68-
* @return \PHPUnit_Framework_MockObject_MockObject|PruneableCacheInterface
69+
* @return MockObject|PruneableCacheInterface
6970
*/
7071
private function getPruneableMock()
7172
{
@@ -82,7 +83,7 @@ private function getPruneableMock()
8283
}
8384

8485
/**
85-
* @return \PHPUnit_Framework_MockObject_MockObject|PruneableCacheInterface
86+
* @return MockObject|PruneableCacheInterface
8687
*/
8788
private function getFailingPruneableMock()
8889
{
@@ -99,7 +100,7 @@ private function getFailingPruneableMock()
99100
}
100101

101102
/**
102-
* @return \PHPUnit_Framework_MockObject_MockObject|AdapterInterface
103+
* @return MockObject|AdapterInterface
103104
*/
104105
private function getNonPruneableMock()
105106
{

src/Symfony/Component/Cache/Tests/Simple/ChainCacheTest.php

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111

1212
namespace Symfony\Component\Cache\Tests\Simple;
1313

14+
use PHPUnit\Framework\MockObject\MockObject;
1415
use Psr\SimpleCache\CacheInterface;
1516
use Symfony\Component\Cache\PruneableInterface;
1617
use Symfony\Component\Cache\Simple\ArrayCache;
@@ -64,7 +65,7 @@ public function testPrune()
6465
}
6566

6667
/**
67-
* @return \PHPUnit_Framework_MockObject_MockObject|PruneableCacheInterface
68+
* @return MockObject|PruneableCacheInterface
6869
*/
6970
private function getPruneableMock()
7071
{
@@ -81,7 +82,7 @@ private function getPruneableMock()
8182
}
8283

8384
/**
84-
* @return \PHPUnit_Framework_MockObject_MockObject|PruneableCacheInterface
85+
* @return MockObject|PruneableCacheInterface
8586
*/
8687
private function getFailingPruneableMock()
8788
{
@@ -98,7 +99,7 @@ private function getFailingPruneableMock()
9899
}
99100

100101
/**
101-
* @return \PHPUnit_Framework_MockObject_MockObject|CacheInterface
102+
* @return MockObject|CacheInterface
102103
*/
103104
private function getNonPruneableMock()
104105
{

src/Symfony/Component/EventDispatcher/Tests/ImmutableEventDispatcherTest.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111

1212
namespace Symfony\Component\EventDispatcher\Tests;
1313

14+
use PHPUnit\Framework\MockObject\MockObject;
1415
use PHPUnit\Framework\TestCase;
1516
use Symfony\Component\EventDispatcher\Event;
1617
use Symfony\Component\EventDispatcher\ImmutableEventDispatcher;
@@ -21,7 +22,7 @@
2122
class ImmutableEventDispatcherTest extends TestCase
2223
{
2324
/**
24-
* @var \PHPUnit_Framework_MockObject_MockObject
25+
* @var MockObject
2526
*/
2627
private $innerDispatcher;
2728

src/Symfony/Component/Form/ChoiceList/ArrayChoiceList.php

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -172,13 +172,13 @@ public function getValuesForChoices(array $choices)
172172
/**
173173
* Flattens an array into the given output variables.
174174
*
175-
* @param array $choices The array to flatten
176-
* @param callable $value The callable for generating choice values
177-
* @param array $choicesByValues The flattened choices indexed by the
178-
* corresponding values
179-
* @param array $keysByValues The original keys indexed by the
180-
* corresponding values
181-
* @param array $structuredValues The values indexed by the original keys
175+
* @param array $choices The array to flatten
176+
* @param callable $value The callable for generating choice values
177+
* @param array|null $choicesByValues The flattened choices indexed by the
178+
* corresponding values
179+
* @param array|null $keysByValues The original keys indexed by the
180+
* corresponding values
181+
* @param array|null $structuredValues The values indexed by the original keys
182182
*
183183
* @internal
184184
*/

0 commit comments

Comments
 (0)