Failed Conditions
CANCELLED  
Pull Request — master (#7095)
by Benjamin
10:13
created
Doctrine/Tests/ORM/Persisters/BasicEntityPersisterCompositeTypeSqlTest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@
 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\Persisters;
6 6
 
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Functional/SchemaTool/PostgreSqlSchemaToolTest.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\Functional\SchemaTool;
6 6
 
@@ -16,7 +16,7 @@  discard block
 block discarded – undo
16 16
         parent::setUp();
17 17
 
18 18
         if ($this->em->getConnection()->getDatabasePlatform()->getName() !== 'postgresql') {
19
-            $this->markTestSkipped('The ' . __CLASS__ .' requires the use of postgresql.');
19
+            $this->markTestSkipped('The '.__CLASS__.' requires the use of postgresql.');
20 20
         }
21 21
     }
22 22
 
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Functional/SchemaTool/CompanySchemaTest.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\Functional\SchemaTool;
6 6
 
@@ -58,7 +58,7 @@  discard block
 block discarded – undo
58 58
      */
59 59
     public function testDropPartSchemaWithForeignKeys()
60 60
     {
61
-        if (!$this->em->getConnection()->getDatabasePlatform()->supportsForeignKeyConstraints()) {
61
+        if ( ! $this->em->getConnection()->getDatabasePlatform()->supportsForeignKeyConstraints()) {
62 62
             $this->markTestSkipped("Foreign Key test");
63 63
         }
64 64
 
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Functional/SchemaTool/DBAL483Test.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\Functional\SchemaTool;
6 6
 
@@ -30,7 +30,7 @@  discard block
 block discarded – undo
30 30
 
31 31
         $updateSql = $this->schemaTool->getUpdateSchemaSql([$class]);
32 32
 
33
-        $updateSql = array_filter($updateSql, function ($sql) {
33
+        $updateSql = array_filter($updateSql, function($sql) {
34 34
             return strpos($sql, 'DBAL483') !== false;
35 35
         });
36 36
 
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Functional/HydrationCacheTest.php 2 patches
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -36,37 +36,37 @@
 block discarded – undo
36 36
         $dql = "SELECT u FROM Doctrine\Tests\Models\Cms\CmsUser u";
37 37
 
38 38
         $users = $this->em->createQuery($dql)
39
-                      ->setHydrationCacheProfile(new QueryCacheProfile(null, null, $cache))
40
-                      ->getResult();
39
+                        ->setHydrationCacheProfile(new QueryCacheProfile(null, null, $cache))
40
+                        ->getResult();
41 41
 
42 42
         $c = $this->getCurrentQueryCount();
43 43
         $users = $this->em->createQuery($dql)
44
-                      ->setHydrationCacheProfile(new QueryCacheProfile(null, null, $cache))
45
-                      ->getResult();
44
+                        ->setHydrationCacheProfile(new QueryCacheProfile(null, null, $cache))
45
+                        ->getResult();
46 46
 
47 47
         self::assertEquals($c, $this->getCurrentQueryCount(), "Should not execute query. Its cached!");
48 48
 
49 49
         $users = $this->em->createQuery($dql)
50
-                      ->setHydrationCacheProfile(new QueryCacheProfile(null, null, $cache))
51
-                      ->getArrayResult();
50
+                        ->setHydrationCacheProfile(new QueryCacheProfile(null, null, $cache))
51
+                        ->getArrayResult();
52 52
 
53 53
         self::assertEquals($c + 1, $this->getCurrentQueryCount(), "Hydration is part of cache key.");
54 54
 
55 55
         $users = $this->em->createQuery($dql)
56
-                      ->setHydrationCacheProfile(new QueryCacheProfile(null, null, $cache))
57
-                      ->getArrayResult();
56
+                        ->setHydrationCacheProfile(new QueryCacheProfile(null, null, $cache))
57
+                        ->getArrayResult();
58 58
 
59 59
         self::assertEquals($c + 1, $this->getCurrentQueryCount(), "Hydration now cached");
60 60
 
61 61
         $users = $this->em->createQuery($dql)
62
-                      ->setHydrationCacheProfile(new QueryCacheProfile(null, 'cachekey', $cache))
63
-                      ->getArrayResult();
62
+                        ->setHydrationCacheProfile(new QueryCacheProfile(null, 'cachekey', $cache))
63
+                        ->getArrayResult();
64 64
 
65 65
         self::assertTrue($cache->contains('cachekey'), 'Explicit cache key');
66 66
 
67 67
         $users = $this->em->createQuery($dql)
68
-                      ->setHydrationCacheProfile(new QueryCacheProfile(null, 'cachekey', $cache))
69
-                      ->getArrayResult();
68
+                        ->setHydrationCacheProfile(new QueryCacheProfile(null, 'cachekey', $cache))
69
+                        ->getArrayResult();
70 70
         self::assertEquals($c + 2, $this->getCurrentQueryCount(), "Hydration now cached");
71 71
     }
72 72
 
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@
 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\Functional;
6 6
 
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Functional/Locking/OptimisticTest.php 1 patch
Spacing   +3 added lines, -3 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\Functional\Locking;
6 6
 
@@ -118,7 +118,7 @@  discard block
 block discarded – undo
118 118
         $test = new OptimisticStandard();
119 119
 
120 120
         for ($i = 0; $i < 5; $i++) {
121
-            $test->name = 'test' . $i;
121
+            $test->name = 'test'.$i;
122 122
 
123 123
             $this->em->persist($test);
124 124
             $this->em->flush();
@@ -252,7 +252,7 @@  discard block
 block discarded – undo
252 252
         $caughtException = null;
253 253
 
254 254
         try {
255
-            $expectedVersionExpired = DateTime::createFromFormat('U', (string) ($test->version->getTimestamp()-3600));
255
+            $expectedVersionExpired = DateTime::createFromFormat('U', (string) ($test->version->getTimestamp() - 3600));
256 256
 
257 257
             $this->em->lock($test, LockMode::OPTIMISTIC, $expectedVersionExpired);
258 258
         } catch (OptimisticLockException $e) {
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Functional/Locking/GearmanLockTest.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\Functional\Locking;
6 6
 
@@ -19,7 +19,7 @@  discard block
 block discarded – undo
19 19
 
20 20
     protected function setUp()
21 21
     {
22
-        if (!class_exists('GearmanClient', false)) {
22
+        if ( ! class_exists('GearmanClient', false)) {
23 23
             $this->markTestSkipped('pecl/gearman is required for this test to run.');
24 24
         }
25 25
 
@@ -135,11 +135,11 @@  discard block
 block discarded – undo
135 135
         $this->gearman->runTasks();
136 136
 
137 137
         self::assertTrue($this->maxRunTime > $forTime,
138
-            "Because of locking this tests should have run at least " . $forTime . " seconds, ".
139
-            "but only did for " . $this->maxRunTime . " seconds.");
138
+            "Because of locking this tests should have run at least ".$forTime." seconds, ".
139
+            "but only did for ".$this->maxRunTime." seconds.");
140 140
         self::assertTrue($this->maxRunTime < $notLongerThan,
141
-            "The longest task should not run longer than " . $notLongerThan . " seconds, ".
142
-            "but did for " . $this->maxRunTime . " seconds."
141
+            "The longest task should not run longer than ".$notLongerThan." seconds, ".
142
+            "but did for ".$this->maxRunTime." seconds."
143 143
         );
144 144
     }
145 145
 
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Functional/Locking/LockTest.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -212,7 +212,7 @@
 block discarded – undo
212 212
         $this->expectExceptionMessage('The optimistic lock on an entity failed.');
213 213
 
214 214
         $this->em->createQuery($dql)
215
-                  ->setHint(Query::HINT_LOCK_MODE, LockMode::OPTIMISTIC)
216
-                  ->getSQL();
215
+                    ->setHint(Query::HINT_LOCK_MODE, LockMode::OPTIMISTIC)
216
+                    ->getSQL();
217 217
     }
218 218
 }
Please login to merge, or discard this 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\Functional\Locking;
6 6
 
@@ -89,7 +89,7 @@  discard block
 block discarded – undo
89 89
         $article = new CmsArticle();
90 90
 
91 91
         $this->expectException(\InvalidArgumentException::class);
92
-        $this->expectExceptionMessage('Entity ' . CmsArticle::class);
92
+        $this->expectExceptionMessage('Entity '.CmsArticle::class);
93 93
 
94 94
         $this->em->lock($article, LockMode::OPTIMISTIC, $article->version + 1);
95 95
     }
@@ -138,7 +138,7 @@  discard block
 block discarded – undo
138 138
     {
139 139
         $writeLockSql = $this->em->getConnection()->getDatabasePlatform()->getWriteLockSQL();
140 140
 
141
-        if (! $writeLockSql) {
141
+        if ( ! $writeLockSql) {
142 142
             $this->markTestSkipped('Database Driver has no Write Lock support.');
143 143
         }
144 144
 
@@ -173,7 +173,7 @@  discard block
 block discarded – undo
173 173
     {
174 174
         $readLockSql = $this->em->getConnection()->getDatabasePlatform()->getReadLockSQL();
175 175
 
176
-        if (! $readLockSql) {
176
+        if ( ! $readLockSql) {
177 177
             $this->markTestSkipped('Database Driver has no Write Lock support.');
178 178
         }
179 179
 
@@ -206,7 +206,7 @@  discard block
 block discarded – undo
206 206
      */
207 207
     public function testLockOptimisticNonVersionedThrowsExceptionInDQL()
208 208
     {
209
-        $dql = "SELECT u FROM " . CmsUser::class . " u WHERE u.username = 'gblanco'";
209
+        $dql = "SELECT u FROM ".CmsUser::class." u WHERE u.username = 'gblanco'";
210 210
 
211 211
         $this->expectException(OptimisticLockException::class);
212 212
         $this->expectExceptionMessage('The optimistic lock on an entity failed.');
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Functional/NativeQueryTest.php 2 patches
Indentation   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -224,13 +224,13 @@
 block discarded – undo
224 224
 
225 225
         $q = $this->em->createNativeQuery('SELECT id, name, status, phonenumber FROM cms_users INNER JOIN cms_phonenumbers ON id = user_id WHERE username = ?', $rsm);
226 226
         $q2 = $q->setSQL('foo')
227
-          ->setResultSetMapping($rsm)
228
-          ->expireResultCache(true)
229
-          ->setHint('foo', 'bar')
230
-          ->setParameter(1, 'foo')
231
-          ->setParameters($parameters)
232
-          ->setResultCacheDriver(null)
233
-          ->setResultCacheLifetime(3500);
227
+            ->setResultSetMapping($rsm)
228
+            ->expireResultCache(true)
229
+            ->setHint('foo', 'bar')
230
+            ->setParameter(1, 'foo')
231
+            ->setParameters($parameters)
232
+            ->setResultCacheDriver(null)
233
+            ->setResultCacheLifetime(3500);
234 234
 
235 235
         self::assertSame($q, $q2);
236 236
     }
Please login to merge, or discard this 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\Functional;
6 6
 
@@ -477,7 +477,7 @@  discard block
 block discarded – undo
477 477
 
478 478
         $rsm->addRootEntityFromClassMetadata(CmsUser::class, 'u');
479 479
 
480
-        self::assertSQLEquals('u.id AS id0, u.status AS status1, u.username AS username2, u.name AS name3, u.email_id AS email_id4', (string)$rsm);
480
+        self::assertSQLEquals('u.id AS id0, u.status AS status1, u.username AS username2, u.name AS name3, u.email_id AS email_id4', (string) $rsm);
481 481
     }
482 482
 
483 483
     /**
Please login to merge, or discard this patch.