Merge branch '4.3' into 4.4
* 4.3: [Form] Fix inconsistencies Use Phpunit FQDN in tests comments
This commit is contained in:
commit
38143c604f
@ -14,6 +14,7 @@ namespace Symfony\Bridge\Doctrine\Tests\Form\ChoiceList;
|
|||||||
use Doctrine\Common\Persistence\ObjectManager;
|
use Doctrine\Common\Persistence\ObjectManager;
|
||||||
use Doctrine\Common\Persistence\ObjectRepository;
|
use Doctrine\Common\Persistence\ObjectRepository;
|
||||||
use Doctrine\ORM\Mapping\ClassMetadata;
|
use Doctrine\ORM\Mapping\ClassMetadata;
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Bridge\Doctrine\Form\ChoiceList\DoctrineChoiceLoader;
|
use Symfony\Bridge\Doctrine\Form\ChoiceList\DoctrineChoiceLoader;
|
||||||
use Symfony\Bridge\Doctrine\Form\ChoiceList\EntityLoaderInterface;
|
use Symfony\Bridge\Doctrine\Form\ChoiceList\EntityLoaderInterface;
|
||||||
@ -28,17 +29,17 @@ use Symfony\Component\Form\ChoiceList\Factory\ChoiceListFactoryInterface;
|
|||||||
class DoctrineChoiceLoaderTest extends TestCase
|
class DoctrineChoiceLoaderTest extends TestCase
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* @var ChoiceListFactoryInterface|\PHPUnit_Framework_MockObject_MockObject
|
* @var ChoiceListFactoryInterface|MockObject
|
||||||
*/
|
*/
|
||||||
private $factory;
|
private $factory;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var ObjectManager|\PHPUnit_Framework_MockObject_MockObject
|
* @var ObjectManager|MockObject
|
||||||
*/
|
*/
|
||||||
private $om;
|
private $om;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var ObjectRepository|\PHPUnit_Framework_MockObject_MockObject
|
* @var ObjectRepository|MockObject
|
||||||
*/
|
*/
|
||||||
private $repository;
|
private $repository;
|
||||||
|
|
||||||
@ -48,12 +49,12 @@ class DoctrineChoiceLoaderTest extends TestCase
|
|||||||
private $class;
|
private $class;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var IdReader|\PHPUnit_Framework_MockObject_MockObject
|
* @var IdReader|MockObject
|
||||||
*/
|
*/
|
||||||
private $idReader;
|
private $idReader;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var EntityLoaderInterface|\PHPUnit_Framework_MockObject_MockObject
|
* @var EntityLoaderInterface|MockObject
|
||||||
*/
|
*/
|
||||||
private $objectLoader;
|
private $objectLoader;
|
||||||
|
|
||||||
|
@ -16,6 +16,7 @@ use Doctrine\Common\Persistence\ManagerRegistry;
|
|||||||
use Doctrine\ORM\EntityManager;
|
use Doctrine\ORM\EntityManager;
|
||||||
use Doctrine\ORM\EntityRepository;
|
use Doctrine\ORM\EntityRepository;
|
||||||
use Doctrine\ORM\Tools\SchemaTool;
|
use Doctrine\ORM\Tools\SchemaTool;
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use Symfony\Bridge\Doctrine\Form\DoctrineOrmExtension;
|
use Symfony\Bridge\Doctrine\Form\DoctrineOrmExtension;
|
||||||
use Symfony\Bridge\Doctrine\Form\DoctrineOrmTypeGuesser;
|
use Symfony\Bridge\Doctrine\Form\DoctrineOrmTypeGuesser;
|
||||||
use Symfony\Bridge\Doctrine\Form\Type\EntityType;
|
use Symfony\Bridge\Doctrine\Form\Type\EntityType;
|
||||||
@ -53,7 +54,7 @@ class EntityTypeTest extends BaseTypeTest
|
|||||||
private $em;
|
private $em;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject|ManagerRegistry
|
* @var MockObject|ManagerRegistry
|
||||||
*/
|
*/
|
||||||
private $emRegistry;
|
private $emRegistry;
|
||||||
|
|
||||||
|
@ -5,6 +5,7 @@ namespace Symfony\Bundle\FrameworkBundle\Tests\CacheWarmer;
|
|||||||
use Doctrine\Common\Annotations\AnnotationReader;
|
use Doctrine\Common\Annotations\AnnotationReader;
|
||||||
use Doctrine\Common\Annotations\CachedReader;
|
use Doctrine\Common\Annotations\CachedReader;
|
||||||
use Doctrine\Common\Annotations\Reader;
|
use Doctrine\Common\Annotations\Reader;
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use Symfony\Bundle\FrameworkBundle\CacheWarmer\AnnotationsCacheWarmer;
|
use Symfony\Bundle\FrameworkBundle\CacheWarmer\AnnotationsCacheWarmer;
|
||||||
use Symfony\Bundle\FrameworkBundle\Tests\TestCase;
|
use Symfony\Bundle\FrameworkBundle\Tests\TestCase;
|
||||||
use Symfony\Component\Cache\Adapter\NullAdapter;
|
use Symfony\Component\Cache\Adapter\NullAdapter;
|
||||||
@ -72,7 +73,7 @@ class AnnotationsCacheWarmerTest extends TestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return \PHPUnit_Framework_MockObject_MockObject|Reader
|
* @return MockObject|Reader
|
||||||
*/
|
*/
|
||||||
private function getReadOnlyReader()
|
private function getReadOnlyReader()
|
||||||
{
|
{
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Bundle\FrameworkBundle\Tests\Command;
|
namespace Symfony\Bundle\FrameworkBundle\Tests\Command;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use Psr\Cache\CacheItemPoolInterface;
|
use Psr\Cache\CacheItemPoolInterface;
|
||||||
use Symfony\Bundle\FrameworkBundle\Command\CachePoolDeleteCommand;
|
use Symfony\Bundle\FrameworkBundle\Command\CachePoolDeleteCommand;
|
||||||
use Symfony\Bundle\FrameworkBundle\Console\Application;
|
use Symfony\Bundle\FrameworkBundle\Console\Application;
|
||||||
@ -83,7 +84,7 @@ class CachePoolDeleteCommandTest extends TestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return \PHPUnit_Framework_MockObject_MockObject|KernelInterface
|
* @return MockObject|KernelInterface
|
||||||
*/
|
*/
|
||||||
private function getKernel()
|
private function getKernel()
|
||||||
{
|
{
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Bundle\FrameworkBundle\Tests\Command;
|
namespace Symfony\Bundle\FrameworkBundle\Tests\Command;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use Symfony\Bundle\FrameworkBundle\Command\CachePoolPruneCommand;
|
use Symfony\Bundle\FrameworkBundle\Command\CachePoolPruneCommand;
|
||||||
use Symfony\Bundle\FrameworkBundle\Console\Application;
|
use Symfony\Bundle\FrameworkBundle\Console\Application;
|
||||||
use Symfony\Bundle\FrameworkBundle\Tests\TestCase;
|
use Symfony\Bundle\FrameworkBundle\Tests\TestCase;
|
||||||
@ -49,7 +50,7 @@ class CachePruneCommandTest extends TestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return \PHPUnit_Framework_MockObject_MockObject|KernelInterface
|
* @return MockObject|KernelInterface
|
||||||
*/
|
*/
|
||||||
private function getKernel()
|
private function getKernel()
|
||||||
{
|
{
|
||||||
@ -75,7 +76,7 @@ class CachePruneCommandTest extends TestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return \PHPUnit_Framework_MockObject_MockObject|PruneableInterface
|
* @return MockObject|PruneableInterface
|
||||||
*/
|
*/
|
||||||
private function getPruneableInterfaceMock()
|
private function getPruneableInterfaceMock()
|
||||||
{
|
{
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Cache\Tests\Adapter;
|
namespace Symfony\Component\Cache\Tests\Adapter;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use Symfony\Component\Cache\Adapter\AdapterInterface;
|
use Symfony\Component\Cache\Adapter\AdapterInterface;
|
||||||
use Symfony\Component\Cache\Adapter\ArrayAdapter;
|
use Symfony\Component\Cache\Adapter\ArrayAdapter;
|
||||||
use Symfony\Component\Cache\Adapter\ChainAdapter;
|
use Symfony\Component\Cache\Adapter\ChainAdapter;
|
||||||
@ -69,7 +70,7 @@ class ChainAdapterTest extends AdapterTestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return \PHPUnit_Framework_MockObject_MockObject|PruneableCacheInterface
|
* @return MockObject|PruneableCacheInterface
|
||||||
*/
|
*/
|
||||||
private function getPruneableMock()
|
private function getPruneableMock()
|
||||||
{
|
{
|
||||||
@ -86,7 +87,7 @@ class ChainAdapterTest extends AdapterTestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return \PHPUnit_Framework_MockObject_MockObject|PruneableCacheInterface
|
* @return MockObject|PruneableCacheInterface
|
||||||
*/
|
*/
|
||||||
private function getFailingPruneableMock()
|
private function getFailingPruneableMock()
|
||||||
{
|
{
|
||||||
@ -103,7 +104,7 @@ class ChainAdapterTest extends AdapterTestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return \PHPUnit_Framework_MockObject_MockObject|AdapterInterface
|
* @return MockObject|AdapterInterface
|
||||||
*/
|
*/
|
||||||
private function getNonPruneableMock()
|
private function getNonPruneableMock()
|
||||||
{
|
{
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Cache\Tests\Adapter;
|
namespace Symfony\Component\Cache\Tests\Adapter;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use Symfony\Component\Cache\Adapter\AdapterInterface;
|
use Symfony\Component\Cache\Adapter\AdapterInterface;
|
||||||
use Symfony\Component\Cache\Adapter\FilesystemAdapter;
|
use Symfony\Component\Cache\Adapter\FilesystemAdapter;
|
||||||
use Symfony\Component\Cache\Adapter\TagAwareAdapter;
|
use Symfony\Component\Cache\Adapter\TagAwareAdapter;
|
||||||
@ -65,7 +66,7 @@ class TagAwareAdapterTest extends AdapterTestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return \PHPUnit_Framework_MockObject_MockObject|PruneableCacheInterface
|
* @return MockObject|PruneableCacheInterface
|
||||||
*/
|
*/
|
||||||
private function getPruneableMock()
|
private function getPruneableMock()
|
||||||
{
|
{
|
||||||
@ -82,7 +83,7 @@ class TagAwareAdapterTest extends AdapterTestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return \PHPUnit_Framework_MockObject_MockObject|PruneableCacheInterface
|
* @return MockObject|PruneableCacheInterface
|
||||||
*/
|
*/
|
||||||
private function getFailingPruneableMock()
|
private function getFailingPruneableMock()
|
||||||
{
|
{
|
||||||
@ -99,7 +100,7 @@ class TagAwareAdapterTest extends AdapterTestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return \PHPUnit_Framework_MockObject_MockObject|AdapterInterface
|
* @return MockObject|AdapterInterface
|
||||||
*/
|
*/
|
||||||
private function getNonPruneableMock()
|
private function getNonPruneableMock()
|
||||||
{
|
{
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Cache\Tests\Simple;
|
namespace Symfony\Component\Cache\Tests\Simple;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use Psr\SimpleCache\CacheInterface;
|
use Psr\SimpleCache\CacheInterface;
|
||||||
use Symfony\Component\Cache\PruneableInterface;
|
use Symfony\Component\Cache\PruneableInterface;
|
||||||
use Symfony\Component\Cache\Simple\ArrayCache;
|
use Symfony\Component\Cache\Simple\ArrayCache;
|
||||||
@ -64,7 +65,7 @@ class ChainCacheTest extends CacheTestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return \PHPUnit_Framework_MockObject_MockObject|PruneableCacheInterface
|
* @return MockObject|PruneableCacheInterface
|
||||||
*/
|
*/
|
||||||
private function getPruneableMock()
|
private function getPruneableMock()
|
||||||
{
|
{
|
||||||
@ -81,7 +82,7 @@ class ChainCacheTest extends CacheTestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return \PHPUnit_Framework_MockObject_MockObject|PruneableCacheInterface
|
* @return MockObject|PruneableCacheInterface
|
||||||
*/
|
*/
|
||||||
private function getFailingPruneableMock()
|
private function getFailingPruneableMock()
|
||||||
{
|
{
|
||||||
@ -98,7 +99,7 @@ class ChainCacheTest extends CacheTestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return \PHPUnit_Framework_MockObject_MockObject|CacheInterface
|
* @return MockObject|CacheInterface
|
||||||
*/
|
*/
|
||||||
private function getNonPruneableMock()
|
private function getNonPruneableMock()
|
||||||
{
|
{
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\EventDispatcher\Tests;
|
namespace Symfony\Component\EventDispatcher\Tests;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\EventDispatcher\Event;
|
use Symfony\Component\EventDispatcher\Event;
|
||||||
use Symfony\Component\EventDispatcher\ImmutableEventDispatcher;
|
use Symfony\Component\EventDispatcher\ImmutableEventDispatcher;
|
||||||
@ -21,7 +22,7 @@ use Symfony\Component\EventDispatcher\ImmutableEventDispatcher;
|
|||||||
class ImmutableEventDispatcherTest extends TestCase
|
class ImmutableEventDispatcherTest extends TestCase
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $innerDispatcher;
|
private $innerDispatcher;
|
||||||
|
|
||||||
|
@ -172,13 +172,13 @@ class ArrayChoiceList implements ChoiceListInterface
|
|||||||
/**
|
/**
|
||||||
* Flattens an array into the given output variables.
|
* Flattens an array into the given output variables.
|
||||||
*
|
*
|
||||||
* @param array $choices The array to flatten
|
* @param array $choices The array to flatten
|
||||||
* @param callable $value The callable for generating choice values
|
* @param callable $value The callable for generating choice values
|
||||||
* @param array $choicesByValues The flattened choices indexed by the
|
* @param array|null $choicesByValues The flattened choices indexed by the
|
||||||
* corresponding values
|
* corresponding values
|
||||||
* @param array $keysByValues The original keys indexed by the
|
* @param array|null $keysByValues The original keys indexed by the
|
||||||
* corresponding values
|
* corresponding values
|
||||||
* @param array $structuredValues The values indexed by the original keys
|
* @param array|null $structuredValues The values indexed by the original keys
|
||||||
*
|
*
|
||||||
* @internal
|
* @internal
|
||||||
*/
|
*/
|
||||||
|
@ -32,8 +32,7 @@ interface ChoiceListFactoryInterface
|
|||||||
* Null may be passed when the choice list contains the empty value.
|
* Null may be passed when the choice list contains the empty value.
|
||||||
*
|
*
|
||||||
* @param iterable $choices The choices
|
* @param iterable $choices The choices
|
||||||
* @param callable|null $value The callable generating the choice
|
* @param callable|null $value The callable generating the choice values
|
||||||
* values
|
|
||||||
*
|
*
|
||||||
* @return ChoiceListInterface The choice list
|
* @return ChoiceListInterface The choice list
|
||||||
*/
|
*/
|
||||||
@ -46,9 +45,7 @@ interface ChoiceListFactoryInterface
|
|||||||
* The callable receives the choice as only argument.
|
* The callable receives the choice as only argument.
|
||||||
* Null may be passed when the choice list contains the empty value.
|
* Null may be passed when the choice list contains the empty value.
|
||||||
*
|
*
|
||||||
* @param ChoiceLoaderInterface $loader The choice loader
|
* @param callable|null $value The callable generating the choice values
|
||||||
* @param callable|null $value The callable generating the choice
|
|
||||||
* values
|
|
||||||
*
|
*
|
||||||
* @return ChoiceListInterface The choice list
|
* @return ChoiceListInterface The choice list
|
||||||
*/
|
*/
|
||||||
@ -80,7 +77,6 @@ interface ChoiceListFactoryInterface
|
|||||||
* match the keys of the choices. The values should be arrays of HTML
|
* match the keys of the choices. The values should be arrays of HTML
|
||||||
* attributes that should be added to the respective choice.
|
* attributes that should be added to the respective choice.
|
||||||
*
|
*
|
||||||
* @param ChoiceListInterface $list The choice list
|
|
||||||
* @param array|callable|null $preferredChoices The preferred choices
|
* @param array|callable|null $preferredChoices The preferred choices
|
||||||
* @param callable|null $label The callable generating the
|
* @param callable|null $label The callable generating the
|
||||||
* choice labels
|
* choice labels
|
||||||
|
@ -30,10 +30,10 @@ class ChoiceView
|
|||||||
/**
|
/**
|
||||||
* Creates a new choice view.
|
* Creates a new choice view.
|
||||||
*
|
*
|
||||||
* @param mixed $data The original choice
|
* @param mixed $data The original choice
|
||||||
* @param string $value The view representation of the choice
|
* @param string $value The view representation of the choice
|
||||||
* @param string $label The label displayed to humans
|
* @param string|false $label The label displayed to humans; pass false to discard the label
|
||||||
* @param array $attr Additional attributes for the HTML tag
|
* @param array $attr Additional attributes for the HTML tag
|
||||||
*/
|
*/
|
||||||
public function __construct($data, string $value, $label, array $attr = [])
|
public function __construct($data, string $value, $label, array $attr = [])
|
||||||
{
|
{
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Form\Tests;
|
namespace Symfony\Component\Form\Tests;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\EventDispatcher\EventDispatcher;
|
use Symfony\Component\EventDispatcher\EventDispatcher;
|
||||||
use Symfony\Component\EventDispatcher\EventDispatcherInterface;
|
use Symfony\Component\EventDispatcher\EventDispatcherInterface;
|
||||||
@ -66,7 +67,7 @@ abstract class AbstractFormTest extends TestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return \PHPUnit_Framework_MockObject_MockObject
|
* @return MockObject
|
||||||
*/
|
*/
|
||||||
protected function getDataMapper()
|
protected function getDataMapper()
|
||||||
{
|
{
|
||||||
@ -74,7 +75,7 @@ abstract class AbstractFormTest extends TestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return \PHPUnit_Framework_MockObject_MockObject
|
* @return MockObject
|
||||||
*/
|
*/
|
||||||
protected function getDataTransformer()
|
protected function getDataTransformer()
|
||||||
{
|
{
|
||||||
@ -82,7 +83,7 @@ abstract class AbstractFormTest extends TestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return \PHPUnit_Framework_MockObject_MockObject
|
* @return MockObject
|
||||||
*/
|
*/
|
||||||
protected function getFormValidator()
|
protected function getFormValidator()
|
||||||
{
|
{
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Form\Tests\ChoiceList\Factory;
|
namespace Symfony\Component\Form\Tests\ChoiceList\Factory;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\Form\ChoiceList\Factory\CachingFactoryDecorator;
|
use Symfony\Component\Form\ChoiceList\Factory\CachingFactoryDecorator;
|
||||||
|
|
||||||
@ -20,7 +21,7 @@ use Symfony\Component\Form\ChoiceList\Factory\CachingFactoryDecorator;
|
|||||||
class CachingFactoryDecoratorTest extends TestCase
|
class CachingFactoryDecoratorTest extends TestCase
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $decoratedFactory;
|
private $decoratedFactory;
|
||||||
|
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Form\Tests\ChoiceList\Factory;
|
namespace Symfony\Component\Form\Tests\ChoiceList\Factory;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\Form\ChoiceList\Factory\PropertyAccessDecorator;
|
use Symfony\Component\Form\ChoiceList\Factory\PropertyAccessDecorator;
|
||||||
use Symfony\Component\PropertyAccess\PropertyPath;
|
use Symfony\Component\PropertyAccess\PropertyPath;
|
||||||
@ -21,7 +22,7 @@ use Symfony\Component\PropertyAccess\PropertyPath;
|
|||||||
class PropertyAccessDecoratorTest extends TestCase
|
class PropertyAccessDecoratorTest extends TestCase
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $decoratedFactory;
|
private $decoratedFactory;
|
||||||
|
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Form\Tests\ChoiceList;
|
namespace Symfony\Component\Form\Tests\ChoiceList;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\Form\ChoiceList\LazyChoiceList;
|
use Symfony\Component\Form\ChoiceList\LazyChoiceList;
|
||||||
|
|
||||||
@ -25,12 +26,12 @@ class LazyChoiceListTest extends TestCase
|
|||||||
private $list;
|
private $list;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $loadedList;
|
private $loadedList;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $loader;
|
private $loader;
|
||||||
|
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Form\Tests\Extension\Csrf\Type;
|
namespace Symfony\Component\Form\Tests\Extension\Csrf\Type;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use Symfony\Component\Form\AbstractType;
|
use Symfony\Component\Form\AbstractType;
|
||||||
use Symfony\Component\Form\Extension\Csrf\CsrfExtension;
|
use Symfony\Component\Form\Extension\Csrf\CsrfExtension;
|
||||||
use Symfony\Component\Form\FormBuilderInterface;
|
use Symfony\Component\Form\FormBuilderInterface;
|
||||||
@ -33,12 +34,12 @@ class FormTypeCsrfExtensionTest_ChildType extends AbstractType
|
|||||||
class FormTypeCsrfExtensionTest extends TypeTestCase
|
class FormTypeCsrfExtensionTest extends TypeTestCase
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
protected $tokenManager;
|
protected $tokenManager;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
protected $translator;
|
protected $translator;
|
||||||
|
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Form\Tests\Extension\DataCollector;
|
namespace Symfony\Component\Form\Tests\Extension\DataCollector;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\Form\Extension\DataCollector\DataCollectorExtension;
|
use Symfony\Component\Form\Extension\DataCollector\DataCollectorExtension;
|
||||||
|
|
||||||
@ -22,7 +23,7 @@ class DataCollectorExtensionTest extends TestCase
|
|||||||
private $extension;
|
private $extension;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $dataCollector;
|
private $dataCollector;
|
||||||
|
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Form\Tests\Extension\DataCollector;
|
namespace Symfony\Component\Form\Tests\Extension\DataCollector;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\Form\Extension\DataCollector\FormDataCollector;
|
use Symfony\Component\Form\Extension\DataCollector\FormDataCollector;
|
||||||
use Symfony\Component\Form\Form;
|
use Symfony\Component\Form\Form;
|
||||||
@ -20,7 +21,7 @@ use Symfony\Component\Form\FormView;
|
|||||||
class FormDataCollectorTest extends TestCase
|
class FormDataCollectorTest extends TestCase
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $dataExtractor;
|
private $dataExtractor;
|
||||||
|
|
||||||
@ -30,17 +31,17 @@ class FormDataCollectorTest extends TestCase
|
|||||||
private $dataCollector;
|
private $dataCollector;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $dispatcher;
|
private $dispatcher;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $factory;
|
private $factory;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $dataMapper;
|
private $dataMapper;
|
||||||
|
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Form\Tests\Extension\DataCollector;
|
namespace Symfony\Component\Form\Tests\Extension\DataCollector;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\Form\CallbackTransformer;
|
use Symfony\Component\Form\CallbackTransformer;
|
||||||
use Symfony\Component\Form\Exception\TransformationFailedException;
|
use Symfony\Component\Form\Exception\TransformationFailedException;
|
||||||
@ -35,12 +36,12 @@ class FormDataExtractorTest extends TestCase
|
|||||||
private $dataExtractor;
|
private $dataExtractor;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $dispatcher;
|
private $dispatcher;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $factory;
|
private $factory;
|
||||||
|
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Form\Tests\Extension\DataCollector\Type;
|
namespace Symfony\Component\Form\Tests\Extension\DataCollector\Type;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\Form\Extension\DataCollector\Type\DataCollectorTypeExtension;
|
use Symfony\Component\Form\Extension\DataCollector\Type\DataCollectorTypeExtension;
|
||||||
|
|
||||||
@ -22,7 +23,7 @@ class DataCollectorTypeExtensionTest extends TestCase
|
|||||||
private $extension;
|
private $extension;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $dataCollector;
|
private $dataCollector;
|
||||||
|
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Form\Tests;
|
namespace Symfony\Component\Form\Tests;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\Form\FormFactory;
|
use Symfony\Component\Form\FormFactory;
|
||||||
use Symfony\Component\Form\FormTypeGuesserChain;
|
use Symfony\Component\Form\FormTypeGuesserChain;
|
||||||
@ -24,22 +25,22 @@ use Symfony\Component\Form\Guess\ValueGuess;
|
|||||||
class FormFactoryTest extends TestCase
|
class FormFactoryTest extends TestCase
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $guesser1;
|
private $guesser1;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $guesser2;
|
private $guesser2;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $registry;
|
private $registry;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $builder;
|
private $builder;
|
||||||
|
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Form\Tests;
|
namespace Symfony\Component\Form\Tests;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\Form\FormRegistry;
|
use Symfony\Component\Form\FormRegistry;
|
||||||
use Symfony\Component\Form\FormTypeGuesserChain;
|
use Symfony\Component\Form\FormTypeGuesserChain;
|
||||||
@ -37,17 +38,17 @@ class FormRegistryTest extends TestCase
|
|||||||
private $registry;
|
private $registry;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject|ResolvedFormTypeFactoryInterface
|
* @var MockObject|ResolvedFormTypeFactoryInterface
|
||||||
*/
|
*/
|
||||||
private $resolvedTypeFactory;
|
private $resolvedTypeFactory;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $guesser1;
|
private $guesser1;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $guesser2;
|
private $guesser2;
|
||||||
|
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Form\Tests;
|
namespace Symfony\Component\Form\Tests;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\Form\Form;
|
use Symfony\Component\Form\Form;
|
||||||
use Symfony\Component\Form\FormConfigInterface;
|
use Symfony\Component\Form\FormConfigInterface;
|
||||||
@ -25,37 +26,37 @@ use Symfony\Component\OptionsResolver\OptionsResolver;
|
|||||||
class ResolvedFormTypeTest extends TestCase
|
class ResolvedFormTypeTest extends TestCase
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $dispatcher;
|
private $dispatcher;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $factory;
|
private $factory;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $dataMapper;
|
private $dataMapper;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject|FormTypeInterface
|
* @var MockObject|FormTypeInterface
|
||||||
*/
|
*/
|
||||||
private $parentType;
|
private $parentType;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject|FormTypeInterface
|
* @var MockObject|FormTypeInterface
|
||||||
*/
|
*/
|
||||||
private $type;
|
private $type;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject|FormTypeExtensionInterface
|
* @var MockObject|FormTypeExtensionInterface
|
||||||
*/
|
*/
|
||||||
private $extension1;
|
private $extension1;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject|FormTypeExtensionInterface
|
* @var MockObject|FormTypeExtensionInterface
|
||||||
*/
|
*/
|
||||||
private $extension2;
|
private $extension2;
|
||||||
|
|
||||||
@ -384,7 +385,7 @@ class ResolvedFormTypeTest extends TestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return \PHPUnit_Framework_MockObject_MockObject
|
* @return MockObject
|
||||||
*/
|
*/
|
||||||
private function getMockFormType($typeClass = 'Symfony\Component\Form\AbstractType')
|
private function getMockFormType($typeClass = 'Symfony\Component\Form\AbstractType')
|
||||||
{
|
{
|
||||||
@ -392,7 +393,7 @@ class ResolvedFormTypeTest extends TestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return \PHPUnit_Framework_MockObject_MockObject
|
* @return MockObject
|
||||||
*/
|
*/
|
||||||
private function getMockFormTypeExtension()
|
private function getMockFormTypeExtension()
|
||||||
{
|
{
|
||||||
@ -400,7 +401,7 @@ class ResolvedFormTypeTest extends TestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return \PHPUnit_Framework_MockObject_MockObject
|
* @return MockObject
|
||||||
*/
|
*/
|
||||||
private function getMockFormFactory()
|
private function getMockFormFactory()
|
||||||
{
|
{
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\HttpFoundation\Tests\Session\Storage\Handler;
|
namespace Symfony\Component\HttpFoundation\Tests\Session\Storage\Handler;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\HttpFoundation\Session\Storage\Handler\MongoDbSessionHandler;
|
use Symfony\Component\HttpFoundation\Session\Storage\Handler\MongoDbSessionHandler;
|
||||||
|
|
||||||
@ -22,7 +23,7 @@ use Symfony\Component\HttpFoundation\Session\Storage\Handler\MongoDbSessionHandl
|
|||||||
class MongoDbSessionHandlerTest extends TestCase
|
class MongoDbSessionHandlerTest extends TestCase
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $mongo;
|
private $mongo;
|
||||||
private $storage;
|
private $storage;
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Intl\Tests\Data\Bundle\Reader;
|
namespace Symfony\Component\Intl\Tests\Data\Bundle\Reader;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\Intl\Data\Bundle\Reader\BundleEntryReader;
|
use Symfony\Component\Intl\Data\Bundle\Reader\BundleEntryReader;
|
||||||
use Symfony\Component\Intl\Exception\ResourceBundleNotFoundException;
|
use Symfony\Component\Intl\Exception\ResourceBundleNotFoundException;
|
||||||
@ -28,7 +29,7 @@ class BundleEntryReaderTest extends TestCase
|
|||||||
private $reader;
|
private $reader;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject
|
* @var MockObject
|
||||||
*/
|
*/
|
||||||
private $readerImpl;
|
private $readerImpl;
|
||||||
|
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Ldap\Tests;
|
namespace Symfony\Component\Ldap\Tests;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\Ldap\Adapter\AdapterInterface;
|
use Symfony\Component\Ldap\Adapter\AdapterInterface;
|
||||||
use Symfony\Component\Ldap\Adapter\ConnectionInterface;
|
use Symfony\Component\Ldap\Adapter\ConnectionInterface;
|
||||||
@ -19,7 +20,7 @@ use Symfony\Component\Ldap\Ldap;
|
|||||||
|
|
||||||
class LdapTest extends TestCase
|
class LdapTest extends TestCase
|
||||||
{
|
{
|
||||||
/** @var \PHPUnit_Framework_MockObject_MockObject */
|
/** @var MockObject */
|
||||||
private $adapter;
|
private $adapter;
|
||||||
|
|
||||||
/** @var Ldap */
|
/** @var Ldap */
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Lock\Tests\Store;
|
namespace Symfony\Component\Lock\Tests\Store;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use Symfony\Component\Lock\BlockingStoreInterface;
|
use Symfony\Component\Lock\BlockingStoreInterface;
|
||||||
use Symfony\Component\Lock\Exception\LockConflictedException;
|
use Symfony\Component\Lock\Exception\LockConflictedException;
|
||||||
use Symfony\Component\Lock\Key;
|
use Symfony\Component\Lock\Key;
|
||||||
@ -50,11 +51,11 @@ class CombinedStoreTest extends AbstractStoreTest
|
|||||||
return new CombinedStore([new RedisStore($redis)], new UnanimousStrategy());
|
return new CombinedStore([new RedisStore($redis)], new UnanimousStrategy());
|
||||||
}
|
}
|
||||||
|
|
||||||
/** @var \PHPUnit_Framework_MockObject_MockObject */
|
/** @var MockObject */
|
||||||
private $strategy;
|
private $strategy;
|
||||||
/** @var \PHPUnit_Framework_MockObject_MockObject */
|
/** @var MockObject */
|
||||||
private $store1;
|
private $store1;
|
||||||
/** @var \PHPUnit_Framework_MockObject_MockObject */
|
/** @var MockObject */
|
||||||
private $store2;
|
private $store2;
|
||||||
/** @var CombinedStore */
|
/** @var CombinedStore */
|
||||||
private $store;
|
private $store;
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Serializer\Tests\Encoder;
|
namespace Symfony\Component\Serializer\Tests\Encoder;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\Serializer\Encoder\XmlEncoder;
|
use Symfony\Component\Serializer\Encoder\XmlEncoder;
|
||||||
use Symfony\Component\Serializer\Normalizer\CustomNormalizer;
|
use Symfony\Component\Serializer\Normalizer\CustomNormalizer;
|
||||||
@ -879,7 +880,7 @@ XML;
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return \PHPUnit_Framework_MockObject_MockObject|NormalizerInterface
|
* @return MockObject|NormalizerInterface
|
||||||
*/
|
*/
|
||||||
private function createMockDateTimeNormalizer()
|
private function createMockDateTimeNormalizer()
|
||||||
{
|
{
|
||||||
|
@ -2,6 +2,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Serializer\Tests\Normalizer;
|
namespace Symfony\Component\Serializer\Tests\Normalizer;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\Serializer\Mapping\AttributeMetadata;
|
use Symfony\Component\Serializer\Mapping\AttributeMetadata;
|
||||||
use Symfony\Component\Serializer\Mapping\ClassMetadata;
|
use Symfony\Component\Serializer\Mapping\ClassMetadata;
|
||||||
@ -30,7 +31,7 @@ class AbstractNormalizerTest extends TestCase
|
|||||||
private $normalizer;
|
private $normalizer;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var ClassMetadataFactoryInterface|\PHPUnit_Framework_MockObject_MockObject
|
* @var ClassMetadataFactoryInterface|MockObject
|
||||||
*/
|
*/
|
||||||
private $classMetadata;
|
private $classMetadata;
|
||||||
|
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Serializer\Tests\Normalizer;
|
namespace Symfony\Component\Serializer\Tests\Normalizer;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\Serializer\Normalizer\ArrayDenormalizer;
|
use Symfony\Component\Serializer\Normalizer\ArrayDenormalizer;
|
||||||
use Symfony\Component\Serializer\SerializerInterface;
|
use Symfony\Component\Serializer\SerializerInterface;
|
||||||
@ -23,7 +24,7 @@ class ArrayDenormalizerTest extends TestCase
|
|||||||
private $denormalizer;
|
private $denormalizer;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var SerializerInterface|\PHPUnit_Framework_MockObject_MockObject
|
* @var SerializerInterface|MockObject
|
||||||
*/
|
*/
|
||||||
private $serializer;
|
private $serializer;
|
||||||
|
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Serializer\Tests\Normalizer;
|
namespace Symfony\Component\Serializer\Tests\Normalizer;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\Serializer\Normalizer\JsonSerializableNormalizer;
|
use Symfony\Component\Serializer\Normalizer\JsonSerializableNormalizer;
|
||||||
use Symfony\Component\Serializer\Normalizer\NormalizerInterface;
|
use Symfony\Component\Serializer\Normalizer\NormalizerInterface;
|
||||||
@ -28,7 +29,7 @@ class JsonSerializableNormalizerTest extends TestCase
|
|||||||
private $normalizer;
|
private $normalizer;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \PHPUnit_Framework_MockObject_MockObject|SerializerInterface
|
* @var MockObject|SerializerInterface
|
||||||
*/
|
*/
|
||||||
private $serializer;
|
private $serializer;
|
||||||
|
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\Translation\Tests;
|
namespace Symfony\Component\Translation\Tests;
|
||||||
|
|
||||||
|
use PHPUnit\Framework\MockObject\MockObject;
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\Config\Resource\SelfCheckingResourceInterface;
|
use Symfony\Component\Config\Resource\SelfCheckingResourceInterface;
|
||||||
use Symfony\Component\Translation\Loader\ArrayLoader;
|
use Symfony\Component\Translation\Loader\ArrayLoader;
|
||||||
@ -99,7 +100,7 @@ class TranslatorCacheTest extends TestCase
|
|||||||
$catalogue = new MessageCatalogue($locale, []);
|
$catalogue = new MessageCatalogue($locale, []);
|
||||||
$catalogue->addResource(new StaleResource()); // better use a helper class than a mock, because it gets serialized in the cache and re-loaded
|
$catalogue->addResource(new StaleResource()); // better use a helper class than a mock, because it gets serialized in the cache and re-loaded
|
||||||
|
|
||||||
/** @var LoaderInterface|\PHPUnit_Framework_MockObject_MockObject $loader */
|
/** @var LoaderInterface|MockObject $loader */
|
||||||
$loader = $this->getMockBuilder('Symfony\Component\Translation\Loader\LoaderInterface')->getMock();
|
$loader = $this->getMockBuilder('Symfony\Component\Translation\Loader\LoaderInterface')->getMock();
|
||||||
$loader
|
$loader
|
||||||
->expects($this->exactly(2))
|
->expects($this->exactly(2))
|
||||||
|
Reference in New Issue
Block a user