@@ -1,6 +1,6 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | -declare(strict_types=1); |
|
| 3 | +declare(strict_types = 1); |
|
| 4 | 4 | |
| 5 | 5 | namespace Doctrine\Tests\ORM\Entity; |
| 6 | 6 | |
@@ -1,6 +1,6 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | -declare(strict_types=1); |
|
| 3 | +declare(strict_types = 1); |
|
| 4 | 4 | |
| 5 | 5 | namespace Doctrine\Tests\ORM\Repository; |
| 6 | 6 | |
@@ -1,6 +1,6 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | -declare(strict_types=1); |
|
| 3 | +declare(strict_types = 1); |
|
| 4 | 4 | |
| 5 | 5 | namespace Doctrine\Tests\ORM\Sequencing; |
| 6 | 6 | |
@@ -45,13 +45,13 @@ discard block |
||
| 45 | 45 | |
| 46 | 46 | for ($i = 0; $i < 42; ++$i) { |
| 47 | 47 | if ($i % 10 === 0) { |
| 48 | - $this->connection->setQueryResult(new StatementArrayMock([[(int)($i / 10) * 10]])); |
|
| 48 | + $this->connection->setQueryResult(new StatementArrayMock([[(int) ($i / 10) * 10]])); |
|
| 49 | 49 | } |
| 50 | 50 | |
| 51 | 51 | $id = $this->sequenceGenerator->generate($this->entityManager, null); |
| 52 | 52 | |
| 53 | 53 | self::assertSame($i, $id); |
| 54 | - self::assertSame((int)($i / 10) * 10 + 10, $this->sequenceGenerator->getCurrentMaxValue()); |
|
| 54 | + self::assertSame((int) ($i / 10) * 10 + 10, $this->sequenceGenerator->getCurrentMaxValue()); |
|
| 55 | 55 | self::assertSame($i + 1, $this->sequenceGenerator->getNextValue()); |
| 56 | 56 | } |
| 57 | 57 | } |
@@ -1,6 +1,6 @@ discard block |
||
| 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 | |
@@ -33,7 +33,7 @@ discard block |
||
| 33 | 33 | $methods = []; |
| 34 | 34 | |
| 35 | 35 | foreach ($class->getMethods() as $method) { |
| 36 | - if ($method->isConstructor() || $method->isStatic() || !$method->isPublic()) { |
|
| 36 | + if ($method->isConstructor() || $method->isStatic() || ! $method->isPublic()) { |
|
| 37 | 37 | continue; |
| 38 | 38 | } |
| 39 | 39 | |
@@ -52,7 +52,7 @@ discard block |
||
| 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) { |
@@ -1,6 +1,6 @@ |
||
| 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 @@ |
||
| 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 | |
@@ -1,6 +1,6 @@ discard block |
||
| 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 |
||
| 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 |
||
| 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 |
||
| 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, |
@@ -1,6 +1,6 @@ discard block |
||
| 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 |
||
| 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 | /** |
@@ -1,6 +1,6 @@ discard block |
||
| 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 |
||
| 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 | /** |
@@ -1,6 +1,6 @@ discard block |
||
| 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 |
||
| 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 |
||
| 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 |
||
| 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 |
||
| 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 |
||
| 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 | /** |
@@ -2128,12 +2128,12 @@ |
||
| 2128 | 2128 | $this->assertSqlGeneration( |
| 2129 | 2129 | 'SELECT u.id FROM Doctrine\Tests\Models\CMS\CmsUser u WHERE CONCAT(u.name, u.status, \'s\') = ?1', |
| 2130 | 2130 | 'SELECT t0.[id] AS c0 FROM [cms_users] t0 WHERE (t0.[name] + t0.[status] + \'s\') = ?' |
| 2131 | - ); |
|
| 2131 | + ); |
|
| 2132 | 2132 | |
| 2133 | 2133 | $this->assertSqlGeneration( |
| 2134 | 2134 | 'SELECT CONCAT(u.id, u.name, u.status) FROM Doctrine\Tests\Models\CMS\CmsUser u WHERE u.id = ?1', |
| 2135 | 2135 | 'SELECT (t0.[id] + t0.[name] + t0.[status]) AS c0 FROM [cms_users] t0 WHERE t0.[id] = ?' |
| 2136 | - ); |
|
| 2136 | + ); |
|
| 2137 | 2137 | } |
| 2138 | 2138 | |
| 2139 | 2139 | /** |