@@ -233,7 +233,7 @@ discard block |
||
| 233 | 233 | |
| 234 | 234 | $contracts = $this->em->createQuery('SELECT c FROM Doctrine\Tests\Models\Company\CompanyContract c ORDER BY c.id')->getScalarResult(); |
| 235 | 235 | |
| 236 | - $discrValues = array_map(static function ($a) { |
|
| 236 | + $discrValues = array_map(static function($a) { |
|
| 237 | 237 | return $a['c_discr']; |
| 238 | 238 | }, $contracts); |
| 239 | 239 | |
@@ -335,19 +335,19 @@ discard block |
||
| 335 | 335 | |
| 336 | 336 | $repos = $this->em->getRepository(CompanyContract::class); |
| 337 | 337 | $contracts = $repos->findBy(['salesPerson' => $this->salesPerson->getId()]); |
| 338 | - self::assertCount(3, $contracts, 'There should be 3 entities related to ' . $this->salesPerson->getId() . " for 'Doctrine\Tests\Models\Company\CompanyContract'"); |
|
| 338 | + self::assertCount(3, $contracts, 'There should be 3 entities related to '.$this->salesPerson->getId()." for 'Doctrine\Tests\Models\Company\CompanyContract'"); |
|
| 339 | 339 | |
| 340 | 340 | $repos = $this->em->getRepository(CompanyFixContract::class); |
| 341 | 341 | $contracts = $repos->findBy(['salesPerson' => $this->salesPerson->getId()]); |
| 342 | - self::assertCount(1, $contracts, 'There should be 1 entities related to ' . $this->salesPerson->getId() . " for 'Doctrine\Tests\Models\Company\CompanyFixContract'"); |
|
| 342 | + self::assertCount(1, $contracts, 'There should be 1 entities related to '.$this->salesPerson->getId()." for 'Doctrine\Tests\Models\Company\CompanyFixContract'"); |
|
| 343 | 343 | |
| 344 | 344 | $repos = $this->em->getRepository(CompanyFlexContract::class); |
| 345 | 345 | $contracts = $repos->findBy(['salesPerson' => $this->salesPerson->getId()]); |
| 346 | - self::assertCount(2, $contracts, 'There should be 2 entities related to ' . $this->salesPerson->getId() . " for 'Doctrine\Tests\Models\Company\CompanyFlexContract'"); |
|
| 346 | + self::assertCount(2, $contracts, 'There should be 2 entities related to '.$this->salesPerson->getId()." for 'Doctrine\Tests\Models\Company\CompanyFlexContract'"); |
|
| 347 | 347 | |
| 348 | 348 | $repos = $this->em->getRepository(CompanyFlexUltraContract::class); |
| 349 | 349 | $contracts = $repos->findBy(['salesPerson' => $this->salesPerson->getId()]); |
| 350 | - self::assertCount(1, $contracts, 'There should be 1 entities related to ' . $this->salesPerson->getId() . " for 'Doctrine\Tests\Models\Company\CompanyFlexUltraContract'"); |
|
| 350 | + self::assertCount(1, $contracts, 'There should be 1 entities related to '.$this->salesPerson->getId()." for 'Doctrine\Tests\Models\Company\CompanyFlexUltraContract'"); |
|
| 351 | 351 | } |
| 352 | 352 | |
| 353 | 353 | /** |
@@ -137,7 +137,7 @@ discard block |
||
| 137 | 137 | { |
| 138 | 138 | $entity = $event->getEntity(); |
| 139 | 139 | |
| 140 | - if (! ($entity instanceof DDC2602Biography)) { |
|
| 140 | + if ( ! ($entity instanceof DDC2602Biography)) { |
|
| 141 | 141 | return; |
| 142 | 142 | } |
| 143 | 143 | |
@@ -158,7 +158,7 @@ discard block |
||
| 158 | 158 | $fieldSelection = new DDC2602FieldSelection(); |
| 159 | 159 | |
| 160 | 160 | $fieldSelection->field = $field; |
| 161 | - $fieldSelection->choiceList = $field->choiceList->filter(static function ($choice) use ($choiceList) { |
|
| 161 | + $fieldSelection->choiceList = $field->choiceList->filter(static function($choice) use ($choiceList) { |
|
| 162 | 162 | return in_array($choice->id, $choiceList, true); |
| 163 | 163 | }); |
| 164 | 164 | |
@@ -51,7 +51,7 @@ |
||
| 51 | 51 | $this->em->clear(); |
| 52 | 52 | |
| 53 | 53 | $cart = $this->em |
| 54 | - ->createQuery('select ca, c from ' . DDC522Cart::class . ' ca join ca.customer c') |
|
| 54 | + ->createQuery('select ca, c from '.DDC522Cart::class.' ca join ca.customer c') |
|
| 55 | 55 | ->getSingleResult(); |
| 56 | 56 | |
| 57 | 57 | self::assertInstanceOf(DDC522Cart::class, $cart); |
@@ -19,8 +19,8 @@ discard block |
||
| 19 | 19 | try { |
| 20 | 20 | $this->schemaTool->createSchema( |
| 21 | 21 | [ |
| 22 | - $this->em->getClassMetadata(__NAMESPACE__ . '\DDC2084\MyEntity1'), |
|
| 23 | - $this->em->getClassMetadata(__NAMESPACE__ . '\DDC2084\MyEntity2'), |
|
| 22 | + $this->em->getClassMetadata(__NAMESPACE__.'\DDC2084\MyEntity1'), |
|
| 23 | + $this->em->getClassMetadata(__NAMESPACE__.'\DDC2084\MyEntity2'), |
|
| 24 | 24 | ] |
| 25 | 25 | ); |
| 26 | 26 | } catch (Exception $exc) { |
@@ -47,10 +47,10 @@ discard block |
||
| 47 | 47 | { |
| 48 | 48 | $e1 = $this->loadFixture(); |
| 49 | 49 | $e2 = $e1->getMyEntity2(); |
| 50 | - $e = $this->em->find(__NAMESPACE__ . '\DDC2084\MyEntity1', $e2); |
|
| 50 | + $e = $this->em->find(__NAMESPACE__.'\DDC2084\MyEntity1', $e2); |
|
| 51 | 51 | |
| 52 | - self::assertInstanceOf(__NAMESPACE__ . '\DDC2084\MyEntity1', $e); |
|
| 53 | - self::assertInstanceOf(__NAMESPACE__ . '\DDC2084\MyEntity2', $e->getMyEntity2()); |
|
| 52 | + self::assertInstanceOf(__NAMESPACE__.'\DDC2084\MyEntity1', $e); |
|
| 53 | + self::assertInstanceOf(__NAMESPACE__.'\DDC2084\MyEntity2', $e->getMyEntity2()); |
|
| 54 | 54 | self::assertEquals('Foo', $e->getMyEntity2()->getValue()); |
| 55 | 55 | } |
| 56 | 56 | |
@@ -60,7 +60,7 @@ discard block |
||
| 60 | 60 | */ |
| 61 | 61 | public function testinvalidIdentifierBindingEntityException() : void |
| 62 | 62 | { |
| 63 | - $this->em->find(__NAMESPACE__ . '\DDC2084\MyEntity1', new DDC2084\MyEntity2('Foo')); |
|
| 63 | + $this->em->find(__NAMESPACE__.'\DDC2084\MyEntity1', new DDC2084\MyEntity2('Foo')); |
|
| 64 | 64 | } |
| 65 | 65 | } |
| 66 | 66 | |
@@ -80,7 +80,7 @@ discard block |
||
| 80 | 80 | */ |
| 81 | 81 | public function convertToDatabaseValue($value, AbstractPlatform $platform) |
| 82 | 82 | { |
| 83 | - if (! $value instanceof GH6141People) { |
|
| 83 | + if ( ! $value instanceof GH6141People) { |
|
| 84 | 84 | $value = GH6141People::get($value); |
| 85 | 85 | } |
| 86 | 86 | |
@@ -121,7 +121,7 @@ discard block |
||
| 121 | 121 | */ |
| 122 | 122 | public static function get($value) |
| 123 | 123 | { |
| 124 | - if (! self::isValid($value)) { |
|
| 124 | + if ( ! self::isValid($value)) { |
|
| 125 | 125 | throw new InvalidArgumentException(); |
| 126 | 126 | } |
| 127 | 127 | |
@@ -33,8 +33,8 @@ |
||
| 33 | 33 | $uow->scheduleExtraUpdate($user, ['name' => 'changed name']); |
| 34 | 34 | |
| 35 | 35 | $listener = $this->getMockBuilder(stdClass::class) |
| 36 | - ->setMethods([Events::postFlush]) |
|
| 37 | - ->getMock(); |
|
| 36 | + ->setMethods([Events::postFlush]) |
|
| 37 | + ->getMock(); |
|
| 38 | 38 | |
| 39 | 39 | $listener |
| 40 | 40 | ->expects($this->once()) |
@@ -38,7 +38,7 @@ |
||
| 38 | 38 | $listener |
| 39 | 39 | ->expects($this->once()) |
| 40 | 40 | ->method(Events::postFlush) |
| 41 | - ->will($this->returnCallback(static function () use ($uow) { |
|
| 41 | + ->will($this->returnCallback(static function() use ($uow) { |
|
| 42 | 42 | self::assertAttributeEmpty('extraUpdates', $uow, 'ExtraUpdates are reset before postFlush'); |
| 43 | 43 | })); |
| 44 | 44 | |
@@ -30,7 +30,7 @@ discard block |
||
| 30 | 30 | ] |
| 31 | 31 | ); |
| 32 | 32 | } catch (Exception $e) { |
| 33 | - $this->fail($e->getMessage() . PHP_EOL . $e->getTraceAsString()); |
|
| 33 | + $this->fail($e->getMessage().PHP_EOL.$e->getTraceAsString()); |
|
| 34 | 34 | } |
| 35 | 35 | } |
| 36 | 36 | |
@@ -39,7 +39,7 @@ discard block |
||
| 39 | 39 | $conn = static::$sharedConn; |
| 40 | 40 | |
| 41 | 41 | // In case test is skipped, tearDown is called, but no setup may have run |
| 42 | - if (! $conn) { |
|
| 42 | + if ( ! $conn) { |
|
| 43 | 43 | return; |
| 44 | 44 | } |
| 45 | 45 | |
@@ -81,7 +81,7 @@ discard block |
||
| 81 | 81 | |
| 82 | 82 | $baz = $this->em->find(get_class($baz), $baz->id); |
| 83 | 83 | foreach ($baz->foos as $foo) { |
| 84 | - self::assertEquals(1, $foo->loaded, 'should have loaded callback counter incremented for ' . get_class($foo)); |
|
| 84 | + self::assertEquals(1, $foo->loaded, 'should have loaded callback counter incremented for '.get_class($foo)); |
|
| 85 | 85 | } |
| 86 | 86 | } |
| 87 | 87 | |
@@ -105,7 +105,7 @@ discard block |
||
| 105 | 105 | self::assertEquals(1, $bar->loaded); |
| 106 | 106 | self::assertEquals(1, $bar->subLoaded); |
| 107 | 107 | |
| 108 | - $dql = 'SELECT b FROM ' . __NAMESPACE__ . '\DDC1655Bar b WHERE b.id = ?1'; |
|
| 108 | + $dql = 'SELECT b FROM '.__NAMESPACE__.'\DDC1655Bar b WHERE b.id = ?1'; |
|
| 109 | 109 | $bar = $this->em->createQuery($dql)->setParameter(1, $bar->id)->getSingleResult(); |
| 110 | 110 | |
| 111 | 111 | self::assertEquals(1, $bar->loaded); |
@@ -32,7 +32,7 @@ |
||
| 32 | 32 | |
| 33 | 33 | $updateSql = $this->schemaTool->getUpdateSchemaSql([$class]); |
| 34 | 34 | |
| 35 | - $updateSql = array_filter($updateSql, static function ($sql) { |
|
| 35 | + $updateSql = array_filter($updateSql, static function($sql) { |
|
| 36 | 36 | return strpos($sql, 'DBAL483') !== false; |
| 37 | 37 | }); |
| 38 | 38 | |
@@ -89,10 +89,10 @@ |
||
| 89 | 89 | $schemaDiff = $comparator->compare($fromSchema, $toSchema); |
| 90 | 90 | |
| 91 | 91 | $sql = $schemaDiff->toSql($this->em->getConnection()->getDatabasePlatform()); |
| 92 | - $sql = array_filter($sql, static function ($sql) { |
|
| 92 | + $sql = array_filter($sql, static function($sql) { |
|
| 93 | 93 | return strpos($sql, 'DROP') === false; |
| 94 | 94 | }); |
| 95 | 95 | |
| 96 | - self::assertCount(0, $sql, 'SQL: ' . implode(PHP_EOL, $sql)); |
|
| 96 | + self::assertCount(0, $sql, 'SQL: '.implode(PHP_EOL, $sql)); |
|
| 97 | 97 | } |
| 98 | 98 | } |