Failed Conditions
Pull Request — develop (#6873)
by
unknown
112:44 queued 47:41
created
tests/Doctrine/Tests/ORM/Query/SqlWalkerTest.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\Query;
6 6
 
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Query/ExprTest.php 2 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -233,7 +233,7 @@
 block discarded – undo
233 233
      */
234 234
     public function testLiteralExprProperlyQuotesStrings()
235 235
     {
236
-       self::assertEquals("'00010001'", (string) $this->expr->literal('00010001'));
236
+        self::assertEquals("'00010001'", (string) $this->expr->literal('00010001'));
237 237
     }
238 238
 
239 239
     public function testGreaterThanOrEqualToExpr()
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\Query;
6 6
 
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Query/QueryTest.php 2 patches
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -88,18 +88,18 @@
 block discarded – undo
88 88
     {
89 89
         $q = $this->em->createQuery("select a from Doctrine\Tests\Models\CMS\CmsArticle a");
90 90
         $q2 = $q->expireQueryCache(true)
91
-          ->setQueryCacheLifetime(3600)
92
-          ->setQueryCacheDriver(null)
93
-          ->expireResultCache(true)
94
-          ->setHint('foo', 'bar')
95
-          ->setHint('bar', 'baz')
96
-          ->setParameter(1, 'bar')
97
-          ->setParameters(new ArrayCollection([new Parameter(2, 'baz')]))
98
-          ->setResultCacheDriver(null)
99
-          ->setResultCacheId('foo')
100
-          ->setDQL('foo')
101
-          ->setFirstResult(10)
102
-          ->setMaxResults(10);
91
+            ->setQueryCacheLifetime(3600)
92
+            ->setQueryCacheDriver(null)
93
+            ->expireResultCache(true)
94
+            ->setHint('foo', 'bar')
95
+            ->setHint('bar', 'baz')
96
+            ->setParameter(1, 'bar')
97
+            ->setParameters(new ArrayCollection([new Parameter(2, 'baz')]))
98
+            ->setResultCacheDriver(null)
99
+            ->setResultCacheId('foo')
100
+            ->setDQL('foo')
101
+            ->setFirstResult(10)
102
+            ->setMaxResults(10);
103 103
 
104 104
         self::assertSame($q2, $q);
105 105
     }
Please login to merge, or discard this 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\Query;
6 6
 
@@ -166,7 +166,7 @@  discard block
 block discarded – undo
166 166
             9 => "St Julien"
167 167
         ];
168 168
 
169
-        $query  = $this->em
169
+        $query = $this->em
170 170
                 ->createQuery("SELECT a FROM Doctrine\Tests\Models\CMS\CmsAddress a WHERE a.city IN (:cities)")
171 171
                 ->setParameter('cities', $cities);
172 172
 
@@ -182,7 +182,7 @@  discard block
 block discarded – undo
182 182
      */
183 183
     public function testProcessParameterValueClassMetadata()
184 184
     {
185
-        $query  = $this->em->createQuery("SELECT a FROM Doctrine\Tests\Models\CMS\CmsAddress a WHERE a.city IN (:cities)");
185
+        $query = $this->em->createQuery("SELECT a FROM Doctrine\Tests\Models\CMS\CmsAddress a WHERE a.city IN (:cities)");
186 186
         self::assertEquals(
187 187
             CmsAddress::class,
188 188
             $query->processParameterValue($this->em->getClassMetadata(CmsAddress::class))
@@ -316,7 +316,7 @@  discard block
 block discarded – undo
316 316
      */
317 317
     public function testGetParameterTypeJuggling() : void
318 318
     {
319
-        $query = $this->_em->createQuery('select u from ' . CmsUser::class . ' u where u.id = ?0');
319
+        $query = $this->_em->createQuery('select u from '.CmsUser::class.' u where u.id = ?0');
320 320
 
321 321
         $query->setParameter(0, 0);
322 322
 
@@ -330,7 +330,7 @@  discard block
 block discarded – undo
330 330
      */
331 331
     public function testSetParameterWithNameZeroIsNotOverridden() : void
332 332
     {
333
-        $query = $this->_em->createQuery('select u from ' . CmsUser::class . ' u where u.id != ?0 and u.username = :name');
333
+        $query = $this->_em->createQuery('select u from '.CmsUser::class.' u where u.id != ?0 and u.username = :name');
334 334
 
335 335
         $query->setParameter(0, 0);
336 336
         $query->setParameter('name', 'Doctrine');
@@ -345,7 +345,7 @@  discard block
 block discarded – undo
345 345
      */
346 346
     public function testSetParameterWithNameZeroDoesNotOverrideAnotherParameter() : void
347 347
     {
348
-        $query = $this->_em->createQuery('select u from ' . CmsUser::class . ' u where u.id != ?0 and u.username = :name');
348
+        $query = $this->_em->createQuery('select u from '.CmsUser::class.' u where u.id != ?0 and u.username = :name');
349 349
 
350 350
         $query->setParameter('name', 'Doctrine');
351 351
         $query->setParameter(0, 0);
@@ -360,7 +360,7 @@  discard block
 block discarded – undo
360 360
      */
361 361
     public function testSetParameterWithTypeJugglingWorks() : void
362 362
     {
363
-        $query = $this->_em->createQuery('select u from ' . CmsUser::class . ' u where u.id != ?0 and u.username = :name');
363
+        $query = $this->_em->createQuery('select u from '.CmsUser::class.' u where u.id != ?0 and u.username = :name');
364 364
 
365 365
         $query->setParameter('0', 1);
366 366
         $query->setParameter('name', 'Doctrine');
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Query/CustomTreeWalkersJoinTest.php 2 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@
 block discarded – undo
30 30
         try {
31 31
             $query = $this->em->createQuery($dqlToBeTested);
32 32
             $query->setHint(Query::HINT_CUSTOM_TREE_WALKERS, [CustomTreeWalkerJoin::class])
33
-                  ->useQueryCache(false);
33
+                    ->useQueryCache(false);
34 34
 
35 35
             $sqlGenerated = $query->getSql();
36 36
 
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\Query;
6 6
 
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
 
37 37
             $query->free();
38 38
         } catch (\Exception $e) {
39
-            $this->fail($e->getMessage() . ' at "' . $e->getFile() . '" on line ' . $e->getLine());
39
+            $this->fail($e->getMessage().' at "'.$e->getFile().'" on line '.$e->getLine());
40 40
         }
41 41
 
42 42
         self::assertEquals($sqlToBeConfirmed, $sqlGenerated);
@@ -78,9 +78,9 @@  discard block
 block discarded – undo
78 78
     {
79 79
         $rangeVariableDecl       = $identificationVariableDecl->rangeVariableDeclaration;
80 80
         $joinAssocPathExpression = new Query\AST\JoinAssociationPathExpression($rangeVariableDecl->aliasIdentificationVariable, 'address');
81
-        $joinAssocDeclaration    = new Query\AST\JoinAssociationDeclaration($joinAssocPathExpression, $rangeVariableDecl->aliasIdentificationVariable . 'a', null);
81
+        $joinAssocDeclaration    = new Query\AST\JoinAssociationDeclaration($joinAssocPathExpression, $rangeVariableDecl->aliasIdentificationVariable.'a', null);
82 82
         $join                    = new Query\AST\Join(Query\AST\Join::JOIN_TYPE_LEFT, $joinAssocDeclaration);
83
-        $selectExpression        = new Query\AST\SelectExpression($rangeVariableDecl->aliasIdentificationVariable . 'a', null, false);
83
+        $selectExpression        = new Query\AST\SelectExpression($rangeVariableDecl->aliasIdentificationVariable.'a', null, false);
84 84
 
85 85
         $identificationVariableDecl->joins[]                = $join;
86 86
         $selectStatement->selectClause->selectExpressions[] = $selectExpression;
@@ -89,7 +89,7 @@  discard block
 block discarded – undo
89 89
         $userMetadata    = $entityManager->getClassMetadata(CmsUser::class);
90 90
         $addressMetadata = $entityManager->getClassMetadata(CmsAddress::class);
91 91
 
92
-        $this->setQueryComponent($rangeVariableDecl->aliasIdentificationVariable . 'a',
92
+        $this->setQueryComponent($rangeVariableDecl->aliasIdentificationVariable.'a',
93 93
             [
94 94
                 'metadata'     => $addressMetadata,
95 95
                 'parent'       => $rangeVariableDecl->aliasIdentificationVariable,
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Query/QueryExpressionVisitorTest.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\Query;
6 6
 
@@ -30,7 +30,7 @@  discard block
 block discarded – undo
30 30
      */
31 31
     protected function setUp()
32 32
     {
33
-        $this->visitor = new QueryExpressionVisitor(['o','p']);
33
+        $this->visitor = new QueryExpressionVisitor(['o', 'p']);
34 34
     }
35 35
 
36 36
     /**
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Query/ParserTest.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\Query;
6 6
 
@@ -31,9 +31,9 @@  discard block
 block discarded – undo
31 31
      */
32 32
     public function testAbstractSchemaNameSupportsClassnamesWithLeadingBackslash()
33 33
     {
34
-        $parser = $this->createParser('\\' . CmsUser::class);
34
+        $parser = $this->createParser('\\'.CmsUser::class);
35 35
 
36
-        self::assertEquals('\\' . CmsUser::class, $parser->AbstractSchemaName());
36
+        self::assertEquals('\\'.CmsUser::class, $parser->AbstractSchemaName());
37 37
     }
38 38
 
39 39
     /**
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Query/SelectSqlGenerationTest.php 2 patches
Indentation   +19 added lines, -19 removed lines patch added patch discarded remove patch
@@ -1657,9 +1657,9 @@  discard block
 block discarded – undo
1657 1657
         );
1658 1658
     }
1659 1659
 
1660
-     /**
1661
-     * @group DDC-1430
1662
-     */
1660
+        /**
1661
+         * @group DDC-1430
1662
+         */
1663 1663
     public function testGroupByAllFieldsWhenObjectHasForeignKeys()
1664 1664
     {
1665 1665
         $this->assertSqlGeneration(
@@ -1999,9 +1999,9 @@  discard block
 block discarded – undo
1999 1999
         );
2000 2000
     }
2001 2001
 
2002
-   /**
2003
-    * @group DDC-1845
2004
-    */
2002
+    /**
2003
+     * @group DDC-1845
2004
+     */
2005 2005
     public function testQuotedWalkJoinVariableDeclaration()
2006 2006
     {
2007 2007
         $this->assertSqlGeneration(
@@ -2035,9 +2035,9 @@  discard block
 block discarded – undo
2035 2035
         );
2036 2036
     }
2037 2037
 
2038
-   /**
2039
-    * @group DDC-2208
2040
-    */
2038
+    /**
2039
+     * @group DDC-2208
2040
+     */
2041 2041
     public function testCaseThenParameterArithmeticExpression()
2042 2042
     {
2043 2043
         $this->assertSqlGeneration(
@@ -2057,8 +2057,8 @@  discard block
 block discarded – undo
2057 2057
     }
2058 2058
 
2059 2059
     /**
2060
-    * @group DDC-2268
2061
-    */
2060
+     * @group DDC-2268
2061
+     */
2062 2062
     public function testCaseThenFunction()
2063 2063
     {
2064 2064
         $this->assertSqlGeneration(
@@ -2123,17 +2123,17 @@  discard block
 block discarded – undo
2123 2123
         $this->assertSqlGeneration(
2124 2124
             'SELECT u.id FROM Doctrine\Tests\Models\CMS\CmsUser u WHERE CONCAT(u.name, u.status, \'s\') = ?1',
2125 2125
             'SELECT t0.[id] AS c0 FROM [cms_users] t0 WHERE (t0.[name] + t0.[status] + \'s\') = ?'
2126
-    	);
2126
+        );
2127 2127
 
2128
-    	$this->assertSqlGeneration(
2128
+        $this->assertSqlGeneration(
2129 2129
             'SELECT CONCAT(u.id, u.name, u.status) FROM Doctrine\Tests\Models\CMS\CmsUser u WHERE u.id = ?1',
2130 2130
             'SELECT (t0.[id] + t0.[name] + t0.[status]) AS c0 FROM [cms_users] t0 WHERE t0.[id] = ?'
2131
-    	);
2131
+        );
2132 2132
     }
2133 2133
 
2134
-     /**
2135
-     * @group DDC-2188
2136
-     */
2134
+        /**
2135
+         * @group DDC-2188
2136
+         */
2137 2137
     public function testArithmeticPriority()
2138 2138
     {
2139 2139
         $this->assertSqlGeneration(
@@ -2153,8 +2153,8 @@  discard block
 block discarded – undo
2153 2153
     }
2154 2154
 
2155 2155
     /**
2156
-    * @group DDC-2475
2157
-    */
2156
+     * @group DDC-2475
2157
+     */
2158 2158
     public function testOrderByClauseShouldReplaceOrderByRelationMapping()
2159 2159
     {
2160 2160
         $this->assertSqlGeneration(
Please login to merge, or discard this patch.
Spacing   +8 added lines, -8 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\Query;
6 6
 
@@ -64,7 +64,7 @@  discard block
 block discarded – undo
64 64
 
65 65
             $query->free();
66 66
         } catch (\Exception $e) {
67
-            $this->fail($e->getMessage() ."\n".$e->getTraceAsString());
67
+            $this->fail($e->getMessage()."\n".$e->getTraceAsString());
68 68
         }
69 69
 
70 70
         self::assertEquals($sqlToBeConfirmed, $sqlGenerated);
@@ -1614,7 +1614,7 @@  discard block
 block discarded – undo
1614 1614
     public function testAliasDoesNotExceedPlatformDefinedLength()
1615 1615
     {
1616 1616
         $this->assertSqlGeneration(
1617
-            'SELECT m FROM ' . __NAMESPACE__ .  '\\DDC1384Model m',
1617
+            'SELECT m FROM '.__NAMESPACE__.'\\DDC1384Model m',
1618 1618
             'SELECT t0."aVeryLongIdentifierThatShouldBeShortenedByTheSQLWalker_fooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo" AS c0 FROM "DDC1384Model" t0'
1619 1619
         );
1620 1620
     }
@@ -1647,12 +1647,12 @@  discard block
 block discarded – undo
1647 1647
     public function testSelectWithArithmeticExpressionBeforeField()
1648 1648
     {
1649 1649
         $this->assertSqlGeneration(
1650
-            'SELECT - e.value AS value, e.id FROM ' . __NAMESPACE__ . '\DDC1474Entity e',
1650
+            'SELECT - e.value AS value, e.id FROM '.__NAMESPACE__.'\DDC1474Entity e',
1651 1651
             'SELECT -t0."value" AS c0, t0."id" AS c1 FROM "DDC1474Entity" t0'
1652 1652
         );
1653 1653
 
1654 1654
         $this->assertSqlGeneration(
1655
-            'SELECT e.id, + e.value AS value FROM ' . __NAMESPACE__ . '\DDC1474Entity e',
1655
+            'SELECT e.id, + e.value AS value FROM '.__NAMESPACE__.'\DDC1474Entity e',
1656 1656
             'SELECT t0."id" AS c0, +t0."value" AS c1 FROM "DDC1474Entity" t0'
1657 1657
         );
1658 1658
     }
@@ -2328,8 +2328,8 @@  discard block
 block discarded – undo
2328 2328
     public function testHavingRegressionUsingVariableWithMathOperatorsExpression($operator)
2329 2329
     {
2330 2330
         $this->assertSqlGeneration(
2331
-            'SELECT COUNT(u.name) AS countName FROM Doctrine\Tests\Models\CMS\CmsUser u HAVING 1 ' . $operator . ' countName > 0',
2332
-            'SELECT COUNT(t0."name") AS c0 FROM "cms_users" t0 HAVING 1 ' . $operator . ' c0 > 0'
2331
+            'SELECT COUNT(u.name) AS countName FROM Doctrine\Tests\Models\CMS\CmsUser u HAVING 1 '.$operator.' countName > 0',
2332
+            'SELECT COUNT(t0."name") AS c0 FROM "cms_users" t0 HAVING 1 '.$operator.' c0 > 0'
2333 2333
         );
2334 2334
     }
2335 2335
 
@@ -2351,7 +2351,7 @@  discard block
 block discarded – undo
2351 2351
      */
2352 2352
     public function getSql(SqlWalker $sqlWalker)
2353 2353
     {
2354
-        return 'ABS(' . $sqlWalker->walkSimpleArithmeticExpression($this->simpleArithmeticExpression) . ')';
2354
+        return 'ABS('.$sqlWalker->walkSimpleArithmeticExpression($this->simpleArithmeticExpression).')';
2355 2355
     }
2356 2356
 
2357 2357
     /**
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Query/DeleteSqlGenerationTest.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\Query;
6 6
 use Doctrine\Tests\OrmTestCase;
Please login to merge, or discard this patch.
tests/Doctrine/Tests/ORM/Query/CustomTreeWalkersTest.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\Functional;
6 6
 
@@ -45,7 +45,7 @@  discard block
 block discarded – undo
45 45
         try {
46 46
             $sqlGenerated = $this->generateSql($dqlToBeTested, $treeWalkers, $outputWalker);
47 47
         } catch (\Exception $e) {
48
-            $this->fail($e->getMessage() . ' at "' . $e->getFile() . '" on line ' . $e->getLine());
48
+            $this->fail($e->getMessage().' at "'.$e->getFile().'" on line '.$e->getLine());
49 49
         }
50 50
 
51 51
         self::assertEquals($sqlToBeConfirmed, $sqlGenerated);
@@ -205,9 +205,9 @@  discard block
 block discarded – undo
205 205
     {
206 206
         $rangeVariableDecl       = $identificationVariableDecl->rangeVariableDeclaration;
207 207
         $joinAssocPathExpression = new Query\AST\JoinAssociationPathExpression($rangeVariableDecl->aliasIdentificationVariable, 'address');
208
-        $joinAssocDeclaration    = new Query\AST\JoinAssociationDeclaration($joinAssocPathExpression, $rangeVariableDecl->aliasIdentificationVariable . 'a', null);
208
+        $joinAssocDeclaration    = new Query\AST\JoinAssociationDeclaration($joinAssocPathExpression, $rangeVariableDecl->aliasIdentificationVariable.'a', null);
209 209
         $join                    = new Query\AST\Join(Query\AST\Join::JOIN_TYPE_LEFT, $joinAssocDeclaration);
210
-        $selectExpression        = new Query\AST\SelectExpression($rangeVariableDecl->aliasIdentificationVariable . 'a', null, false);
210
+        $selectExpression        = new Query\AST\SelectExpression($rangeVariableDecl->aliasIdentificationVariable.'a', null, false);
211 211
 
212 212
         $identificationVariableDecl->joins[]                = $join;
213 213
         $selectStatement->selectClause->selectExpressions[] = $selectExpression;
@@ -216,7 +216,7 @@  discard block
 block discarded – undo
216 216
         $userMetadata    = $entityManager->getClassMetadata(CmsUser::class);
217 217
         $addressMetadata = $entityManager->getClassMetadata(CmsAddress::class);
218 218
 
219
-        $this->setQueryComponent($rangeVariableDecl->aliasIdentificationVariable . 'a',
219
+        $this->setQueryComponent($rangeVariableDecl->aliasIdentificationVariable.'a',
220 220
             [
221 221
                 'metadata'     => $addressMetadata,
222 222
                 'parent'       => $rangeVariableDecl->aliasIdentificationVariable,
Please login to merge, or discard this patch.