From 8f772109550b02fe1285322743fd3c1254ee284e Mon Sep 17 00:00:00 2001 From: Marco Pivetta Date: Wed, 16 Aug 2017 15:16:00 +0200 Subject: [PATCH] #6626 #6625 minor CS fixes (removed useless assignments) --- lib/Doctrine/ORM/Proxy/ProxyFactory.php | 4 +++- .../Tests/ORM/Proxy/ProxyFactoryTest.php | 17 ++++++++++------- 2 files changed, 13 insertions(+), 8 deletions(-) diff --git a/lib/Doctrine/ORM/Proxy/ProxyFactory.php b/lib/Doctrine/ORM/Proxy/ProxyFactory.php index fd2178da7..b6e174351 100644 --- a/lib/Doctrine/ORM/Proxy/ProxyFactory.php +++ b/lib/Doctrine/ORM/Proxy/ProxyFactory.php @@ -91,7 +91,9 @@ class ProxyFactory extends AbstractProxyFactory protected function skipClass(ClassMetadata $metadata) { /* @var $metadata \Doctrine\ORM\Mapping\ClassMetadataInfo */ - return $metadata->isMappedSuperclass || $metadata->isEmbeddedClass || $metadata->getReflectionClass()->isAbstract(); + return $metadata->isMappedSuperclass + || $metadata->isEmbeddedClass + || $metadata->getReflectionClass()->isAbstract(); } /** diff --git a/tests/Doctrine/Tests/ORM/Proxy/ProxyFactoryTest.php b/tests/Doctrine/Tests/ORM/Proxy/ProxyFactoryTest.php index b738f9dff..6b0725d2f 100644 --- a/tests/Doctrine/Tests/ORM/Proxy/ProxyFactoryTest.php +++ b/tests/Doctrine/Tests/ORM/Proxy/ProxyFactoryTest.php @@ -71,15 +71,16 @@ class ProxyFactoryTest extends \Doctrine\Tests\OrmTestCase $proxy->getDescription(); } - public function testSkipMappedSuperClassesOnGeneration(): void { $cm = new ClassMetadata(\stdClass::class); $cm->isMappedSuperclass = true; - $num = $this->proxyFactory->generateProxyClasses([$cm]); - - self::assertSame(0, $num, 'No proxies generated.'); + self::assertSame( + 0, + $this->proxyFactory->generateProxyClasses([$cm]), + 'No proxies generated.' + ); } /** @@ -90,9 +91,11 @@ class ProxyFactoryTest extends \Doctrine\Tests\OrmTestCase $cm = new ClassMetadata(\stdClass::class); $cm->isEmbeddedClass = true; - $num = $this->proxyFactory->generateProxyClasses([$cm]); - - self::assertSame(0, $num, 'No proxies generated.'); + self::assertSame( + 0, + $this->proxyFactory->generateProxyClasses([$cm]), + 'No proxies generated.' + ); } /**