Completed
Pull Request — master (#7046)
by Gabriel
13:08
created
tests/Doctrine/Tests/ORM/Hydration/SimpleObjectHydratorTest.php 1 patch
Indentation   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -33,10 +33,10 @@  discard block
 block discarded – undo
33 33
         $rsm->setDiscriminatorColumn('p', 'discr');
34 34
 
35 35
         $resultSet = [
36
-              [
37
-                  'u__id'   => '1',
38
-                  'u__name' => 'Fabio B. Silva',
39
-              ],
36
+                [
37
+                    'u__id'   => '1',
38
+                    'u__name' => 'Fabio B. Silva',
39
+                ],
40 40
         ];
41 41
 
42 42
         $stmt     = new HydratorMockStatement($resultSet);
@@ -89,11 +89,11 @@  discard block
 block discarded – undo
89 89
         $rsm->setDiscriminatorColumn('p', 'discr');
90 90
 
91 91
         $resultSet = [
92
-              [
93
-                  'p__id'   => '1',
94
-                  'p__name' => 'Fabio B. Silva',
95
-                  'discr'   => 'subworker',
96
-              ],
92
+                [
93
+                    'p__id'   => '1',
94
+                    'p__name' => 'Fabio B. Silva',
95
+                    'discr'   => 'subworker',
96
+                ],
97 97
         ];
98 98
 
99 99
         $stmt     = new HydratorMockStatement($resultSet);
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Hydration/AbstractHydratorTest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
-declare(strict_types=1);
3
+declare(strict_types = 1);
4 4
 
5 5
 namespace Doctrine\Tests\ORM\Hydration;
6 6
 
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
         $mockConnection             = $this->createMock(Connection::class);
48 48
         $mockEntityManagerInterface = $this->createMock(EntityManagerInterface::class);
49 49
         $mockUow                    = $this->createMock(UnitOfWork::class);
50
-        $mockMetadataFactory       = $this->createMock(ClassMetadataFactory::class);
50
+        $mockMetadataFactory = $this->createMock(ClassMetadataFactory::class);
51 51
 
52 52
         $this->mockEventManager     = $this->createMock(EventManager::class);
53 53
         $this->mockStatement        = $this->createMock(Statement::class);
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Tools/SchemaValidatorTest.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
-declare(strict_types=1);
3
+declare(strict_types = 1);
4 4
 
5 5
 namespace Doctrine\Tests\ORM\Tools;
6 6
 
@@ -42,12 +42,12 @@  discard block
 block discarded – undo
42 42
     public function modelSetProvider() : array
43 43
     {
44 44
         return [
45
-            'cms'        => [__DIR__ . '/../../Models/CMS'],
46
-            'company'    => [__DIR__ . '/../../Models/Company'],
47
-            'ecommerce'  => [__DIR__ . '/../../Models/ECommerce'],
48
-            'forum'      => [__DIR__ . '/../../Models/Forum'],
49
-            'navigation' => [__DIR__ . '/../../Models/Navigation'],
50
-            'routing'    => [__DIR__ . '/../../Models/Routing'],
45
+            'cms'        => [__DIR__.'/../../Models/CMS'],
46
+            'company'    => [__DIR__.'/../../Models/Company'],
47
+            'ecommerce'  => [__DIR__.'/../../Models/ECommerce'],
48
+            'forum'      => [__DIR__.'/../../Models/Forum'],
49
+            'navigation' => [__DIR__.'/../../Models/Navigation'],
50
+            'routing'    => [__DIR__.'/../../Models/Routing'],
51 51
         ];
52 52
     }
53 53
 
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Tools/SetupTest.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
-declare(strict_types=1);
3
+declare(strict_types = 1);
4 4
 
5 5
 namespace Doctrine\Tests\ORM\Tools;
6 6
 
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
 
26 26
     public function tearDown()
27 27
     {
28
-        if (! $this->originalIncludePath) {
28
+        if ( ! $this->originalIncludePath) {
29 29
             return;
30 30
         }
31 31
 
@@ -40,7 +40,7 @@  discard block
 block discarded – undo
40 40
 
41 41
     public function testDirectoryAutoload()
42 42
     {
43
-        Setup::registerAutoloadDirectory(__DIR__ . '/../../../../../vendor/doctrine/common/lib');
43
+        Setup::registerAutoloadDirectory(__DIR__.'/../../../../../vendor/doctrine/common/lib');
44 44
 
45 45
         self::assertCount($this->originalAutoloaderCount + 2, spl_autoload_functions());
46 46
     }
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
         $config = Setup::createConfiguration(false, __DIR__);
72 72
         $cache  = $config->getMetadataCacheImpl();
73 73
 
74
-        self::assertSame('dc2_' . md5(__DIR__) . '_', $cache->getNamespace());
74
+        self::assertSame('dc2_'.md5(__DIR__).'_', $cache->getNamespace());
75 75
     }
76 76
 
77 77
     /**
@@ -82,7 +82,7 @@  discard block
 block discarded – undo
82 82
         $config = Setup::createConfiguration(false, __DIR__, new ArrayCache());
83 83
         $cache  = $config->getMetadataCacheImpl();
84 84
 
85
-        self::assertSame('dc2_' . md5(__DIR__) . '_', $cache->getNamespace());
85
+        self::assertSame('dc2_'.md5(__DIR__).'_', $cache->getNamespace());
86 86
     }
87 87
 
88 88
     /**
@@ -97,7 +97,7 @@  discard block
 block discarded – undo
97 97
         $cache  = $config->getMetadataCacheImpl();
98 98
 
99 99
         self::assertSame($originalCache, $cache);
100
-        self::assertSame('foo:dc2_' . md5(__DIR__) . '_', $cache->getNamespace());
100
+        self::assertSame('foo:dc2_'.md5(__DIR__).'_', $cache->getNamespace());
101 101
     }
102 102
 
103 103
     /**
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Mapping/AnnotationDriverTest.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
-declare(strict_types=1);
3
+declare(strict_types = 1);
4 4
 
5 5
 namespace Doctrine\Tests\ORM\Mapping;
6 6
 
@@ -119,7 +119,7 @@  discard block
 block discarded – undo
119 119
     protected function loadDriverForCMSModels()
120 120
     {
121 121
         $annotationDriver = $this->loadDriver();
122
-        $annotationDriver->addPaths([__DIR__ . '/../../Models/CMS/']);
122
+        $annotationDriver->addPaths([__DIR__.'/../../Models/CMS/']);
123 123
         return $annotationDriver;
124 124
     }
125 125
 
@@ -141,7 +141,7 @@  discard block
 block discarded – undo
141 141
     public function testJoinTablesWithMappedSuperclassForAnnotationDriver()
142 142
     {
143 143
         $annotationDriver = $this->loadDriver();
144
-        $annotationDriver->addPaths([__DIR__ . '/../../Models/DirectoryTree/']);
144
+        $annotationDriver->addPaths([__DIR__.'/../../Models/DirectoryTree/']);
145 145
 
146 146
         $em = $this->getTestEntityManager();
147 147
         $em->getConfiguration()->setMetadataDriverImpl($annotationDriver);
@@ -171,7 +171,7 @@  discard block
 block discarded – undo
171 171
 
172 172
         $this->expectException(MappingException::class);
173 173
         $this->expectExceptionMessage(
174
-            'It is illegal to put an inverse side one-to-many or many-to-many association on ' .
174
+            'It is illegal to put an inverse side one-to-many or many-to-many association on '.
175 175
             "mapped superclass 'Doctrine\Tests\ORM\Mapping\InvalidMappedSuperClass#users'"
176 176
         );
177 177
 
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Mapping/Symfony/AbstractDriverTest.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
-declare(strict_types=1);
3
+declare(strict_types = 1);
4 4
 
5 5
 namespace Doctrine\Tests\ORM\Mapping\Symfony;
6 6
 
@@ -21,7 +21,7 @@  discard block
 block discarded – undo
21 21
             ]
22 22
         );
23 23
 
24
-        touch($filename = $this->dir . '/Foo' . $this->getFileExtension());
24
+        touch($filename = $this->dir.'/Foo'.$this->getFileExtension());
25 25
         self::assertEquals($filename, $driver->getLocator()->findMappingFile('MyNamespace\MySubnamespace\Entity\Foo'));
26 26
     }
27 27
 
@@ -33,7 +33,7 @@  discard block
 block discarded – undo
33 33
             ]
34 34
         );
35 35
 
36
-        touch($filename = $this->dir . '/Foo.Bar' . $this->getFileExtension());
36
+        touch($filename = $this->dir.'/Foo.Bar'.$this->getFileExtension());
37 37
         self::assertEquals($filename, $driver->getLocator()->findMappingFile('MyNamespace\MySubnamespace\Entity\Foo\Bar'));
38 38
     }
39 39
 
@@ -54,7 +54,7 @@  discard block
 block discarded – undo
54 54
     public function testFindMappingNamespaceNotFound()
55 55
     {
56 56
         $this->expectException(MappingException::class);
57
-        $this->expectExceptionMessage("No mapping file found named 'Foo" . $this->getFileExtension() . "' for class 'MyOtherNamespace\MySubnamespace\Entity\Foo'.");
57
+        $this->expectExceptionMessage("No mapping file found named 'Foo".$this->getFileExtension()."' for class 'MyOtherNamespace\MySubnamespace\Entity\Foo'.");
58 58
 
59 59
         $driver = $this->getDriver(
60 60
             [
@@ -67,7 +67,7 @@  discard block
 block discarded – undo
67 67
 
68 68
     protected function setUp()
69 69
     {
70
-        $this->dir = sys_get_temp_dir() . '/abstract_driver_test';
70
+        $this->dir = sys_get_temp_dir().'/abstract_driver_test';
71 71
         @mkdir($this->dir, 0777, true);
72 72
     }
73 73
 
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Mapping/ClassMetadataFactoryTest.php 1 patch
Spacing   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
-declare(strict_types=1);
3
+declare(strict_types = 1);
4 4
 
5 5
 namespace Doctrine\Tests\ORM\Mapping;
6 6
 
@@ -111,9 +111,9 @@  discard block
 block discarded – undo
111 111
 
112 112
     public function testHasGetMetadata_NamespaceSeparatorIsNotNormalized()
113 113
     {
114
-        require_once __DIR__ . '/../../Models/Global/GlobalNamespaceModel.php';
114
+        require_once __DIR__.'/../../Models/Global/GlobalNamespaceModel.php';
115 115
 
116
-        $metadataDriver = $this->createAnnotationDriver([__DIR__ . '/../../Models/Global/']);
116
+        $metadataDriver = $this->createAnnotationDriver([__DIR__.'/../../Models/Global/']);
117 117
 
118 118
         $entityManager = $this->createEntityManager($metadataDriver);
119 119
 
@@ -121,10 +121,10 @@  discard block
 block discarded – undo
121 121
 
122 122
         self::assertSame(
123 123
             $mf->getMetadataFor(DoctrineGlobal_Article::class),
124
-            $mf->getMetadataFor('\\' . DoctrineGlobal_Article::class)
124
+            $mf->getMetadataFor('\\'.DoctrineGlobal_Article::class)
125 125
         );
126 126
         self::assertTrue($mf->hasMetadataFor(DoctrineGlobal_Article::class));
127
-        self::assertTrue($mf->hasMetadataFor('\\' . DoctrineGlobal_Article::class));
127
+        self::assertTrue($mf->hasMetadataFor('\\'.DoctrineGlobal_Article::class));
128 128
     }
129 129
 
130 130
     /**
@@ -152,7 +152,7 @@  discard block
 block discarded – undo
152 152
     public function testAddDefaultDiscriminatorMap()
153 153
     {
154 154
         $cmf = new ClassMetadataFactory();
155
-        $driver = $this->createAnnotationDriver([__DIR__ . '/../../Models/JoinedInheritanceType/']);
155
+        $driver = $this->createAnnotationDriver([__DIR__.'/../../Models/JoinedInheritanceType/']);
156 156
         $em = $this->createEntityManager($driver);
157 157
         $cmf->setEntityManager($em);
158 158
 
@@ -192,7 +192,7 @@  discard block
 block discarded – undo
192 192
     {
193 193
         // DDC-3551
194 194
         $conn = $this->createMock(Connection::class);
195
-        $mockDriver    = new MetadataDriverMock();
195
+        $mockDriver = new MetadataDriverMock();
196 196
         $conn->expects($this->any())
197 197
             ->method('getEventManager')
198 198
             ->willReturn(new EventManager());
@@ -216,10 +216,10 @@  discard block
 block discarded – undo
216 216
         $driverMock = new DriverMock();
217 217
         $config = new Configuration();
218 218
 
219
-        $config->setProxyDir(__DIR__ . '/../../Proxies');
219
+        $config->setProxyDir(__DIR__.'/../../Proxies');
220 220
         $config->setProxyNamespace('Doctrine\Tests\Proxies');
221 221
 
222
-        if (! $conn) {
222
+        if ( ! $conn) {
223 223
             $conn = new ConnectionMock([], $driverMock, $config, new EventManager());
224 224
         }
225 225
         $eventManager = $conn->getEventManager();
@@ -310,7 +310,7 @@  discard block
 block discarded – undo
310 310
     public function testQuoteMetadata()
311 311
     {
312 312
         $cmf    = new ClassMetadataFactory();
313
-        $driver = $this->createAnnotationDriver([__DIR__ . '/../../Models/Quote/']);
313
+        $driver = $this->createAnnotationDriver([__DIR__.'/../../Models/Quote/']);
314 314
         $em     = $this->createEntityManager($driver);
315 315
         $cmf->setEntityManager($em);
316 316
 
@@ -399,7 +399,7 @@  discard block
 block discarded – undo
399 399
         $listener
400 400
             ->expects($this->any())
401 401
             ->method('onClassMetadataNotFound')
402
-            ->will($this->returnCallback(function (OnClassMetadataNotFoundEventArgs $args) use ($metadata, $em, $test) {
402
+            ->will($this->returnCallback(function(OnClassMetadataNotFoundEventArgs $args) use ($metadata, $em, $test) {
403 403
                 $test->assertNull($args->getFoundMetadata());
404 404
                 $test->assertSame('Foo', $args->getClassName());
405 405
                 $test->assertSame($em, $args->getObjectManager());
@@ -461,7 +461,7 @@  discard block
 block discarded – undo
461 461
     public function testInheritsIdGeneratorMappingFromEmbeddable()
462 462
     {
463 463
         $cmf = new ClassMetadataFactory();
464
-        $driver = $this->createAnnotationDriver([__DIR__ . '/../../Models/DDC4006/']);
464
+        $driver = $this->createAnnotationDriver([__DIR__.'/../../Models/DDC4006/']);
465 465
         $em = $this->createEntityManager($driver);
466 466
         $cmf->setEntityManager($em);
467 467
 
@@ -485,7 +485,7 @@  discard block
 block discarded – undo
485 485
     {
486 486
         $this->requestedClasses[] = $className;
487 487
 
488
-        if (! isset($this->mockMetadata[$className])) {
488
+        if ( ! isset($this->mockMetadata[$className])) {
489 489
             throw new \InvalidArgumentException("No mock metadata found for class $className.");
490 490
         }
491 491
 
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Decorator/EntityManagerDecoratorTest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
-declare(strict_types=1);
3
+declare(strict_types = 1);
4 4
 
5 5
 namespace Doctrine\Tests\ORM\Decorator;
6 6
 
@@ -52,7 +52,7 @@  discard block
 block discarded – undo
52 52
 
53 53
         /** Special case EntityManager::transactional() */
54 54
         if ($method->getName() === 'transactional') {
55
-            return [$method->getName(), [function () {}]];
55
+            return [$method->getName(), [function() {}]];
56 56
         }
57 57
 
58 58
         if ($method->getNumberOfRequiredParameters() === 0) {
Please login to merge, or discard this patch.
tests/Doctrine/Performance/EntityManagerFactory.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
-declare(strict_types=1);
3
+declare(strict_types = 1);
4 4
 
5 5
 namespace Doctrine\Performance;
6 6
 
@@ -17,13 +17,13 @@  discard block
 block discarded – undo
17 17
     {
18 18
         $config = new Configuration();
19 19
 
20
-        $config->setProxyDir(__DIR__ . '/../Tests/Proxies');
20
+        $config->setProxyDir(__DIR__.'/../Tests/Proxies');
21 21
         $config->setProxyNamespace('Doctrine\Tests\Proxies');
22 22
         $config->setAutoGenerateProxyClasses(StaticProxyFactory::AUTOGENERATE_EVAL);
23 23
         $config->setMetadataDriverImpl(
24 24
             $config->newDefaultAnnotationDriver([
25
-                realpath(__DIR__ . '/Models/Cache'),
26
-                realpath(__DIR__ . '/Models/GeoNames'),
25
+                realpath(__DIR__.'/Models/Cache'),
26
+                realpath(__DIR__.'/Models/GeoNames'),
27 27
             ])
28 28
         );
29 29
 
Please login to merge, or discard this patch.