@@ -227,6 +227,9 @@ discard block |
||
227 | 227 | $this->assertEquals([], $metadata); |
228 | 228 | } |
229 | 229 | |
230 | + /** |
|
231 | + * @param \PHPUnit_Framework_MockObject_MockObject $conn |
|
232 | + */ |
|
230 | 233 | protected function _createEntityManager($metadataDriver, $conn = null) |
231 | 234 | { |
232 | 235 | $driverMock = new DriverMock(); |
@@ -255,7 +258,6 @@ discard block |
||
255 | 258 | } |
256 | 259 | |
257 | 260 | /** |
258 | - * @param string $class |
|
259 | 261 | * @return ClassMetadata |
260 | 262 | */ |
261 | 263 | protected function _createValidClassMetadata() |
@@ -469,6 +471,10 @@ discard block |
||
469 | 471 | return $this->mockMetadata[$className]; |
470 | 472 | } |
471 | 473 | |
474 | + /** |
|
475 | + * @param string $className |
|
476 | + * @param ClassMetadata $metadata |
|
477 | + */ |
|
472 | 478 | public function setMetadataForClass($className, $metadata) |
473 | 479 | { |
474 | 480 | $this->mockMetadata[$className] = $metadata; |
@@ -5,7 +5,6 @@ |
||
5 | 5 | use Doctrine\Instantiator\Instantiator; |
6 | 6 | use Doctrine\ORM\Mapping\ReflectionEmbeddedProperty; |
7 | 7 | use Doctrine\Tests\Models\Generic\BooleanModel; |
8 | -use Doctrine\Tests\Models\Mapping\Entity; |
|
9 | 8 | use Doctrine\Tests\Models\Reflection\AbstractEmbeddable; |
10 | 9 | use Doctrine\Tests\Models\Reflection\ArrayObjectExtendingClass; |
11 | 10 | use Doctrine\Tests\Models\Reflection\ConcreteEmbeddable; |
@@ -2,7 +2,6 @@ |
||
2 | 2 | |
3 | 3 | namespace Doctrine\Tests\ORM\Performance; |
4 | 4 | |
5 | -use Doctrine\ORM\Query; |
|
6 | 5 | use Doctrine\Tests\Models\CMS\CmsUser; |
7 | 6 | use Doctrine\Tests\Models\CMS\CmsGroup; |
8 | 7 | use Doctrine\Tests\Models\CMS\CmsArticle; |
@@ -7,7 +7,6 @@ |
||
7 | 7 | use Doctrine\DBAL\Types\Type as DBALType; |
8 | 8 | use Doctrine\ORM\Persisters\Entity\BasicEntityPersister; |
9 | 9 | use Doctrine\Tests\Models\CustomType\CustomTypeChild; |
10 | -use Doctrine\Tests\Models\CustomType\CustomTypeFriend; |
|
11 | 10 | use Doctrine\Tests\Models\CustomType\CustomTypeParent; |
12 | 11 | use Doctrine\Tests\Models\Generic\NonAlphaColumnsEntity; |
13 | 12 | use Doctrine\Tests\OrmTestCase; |
@@ -38,6 +38,10 @@ |
||
38 | 38 | return $query->getSql(); |
39 | 39 | } |
40 | 40 | |
41 | + /** |
|
42 | + * @param string $dqlToBeTested |
|
43 | + * @param string $sqlToBeConfirmed |
|
44 | + */ |
|
41 | 45 | public function assertSqlGeneration($dqlToBeTested, $sqlToBeConfirmed, $treeWalkers = [], $outputWalker = null) |
42 | 46 | { |
43 | 47 | try { |
@@ -4,7 +4,6 @@ |
||
4 | 4 | |
5 | 5 | use Doctrine\Common\Cache\ArrayCache; |
6 | 6 | use Doctrine\Common\Collections\ArrayCollection; |
7 | - |
|
8 | 7 | use Doctrine\ORM\EntityManager; |
9 | 8 | use Doctrine\ORM\Query\Parameter; |
10 | 9 | use Doctrine\Tests\Mocks\DriverConnectionMock; |
@@ -43,6 +43,10 @@ |
||
43 | 43 | $this->_em = $this->_getTestEntityManager(); |
44 | 44 | } |
45 | 45 | |
46 | + /** |
|
47 | + * @param string $dqlToBeTested |
|
48 | + * @param string $sqlToBeConfirmed |
|
49 | + */ |
|
46 | 50 | public function assertSqlGeneration($dqlToBeTested, $sqlToBeConfirmed) |
47 | 51 | { |
48 | 52 | try { |
@@ -35,6 +35,9 @@ |
||
35 | 35 | $this->_em = $this->_getTestEntityManager(); |
36 | 36 | } |
37 | 37 | |
38 | + /** |
|
39 | + * @param string $expectedDql |
|
40 | + */ |
|
38 | 41 | protected function assertValidQueryBuilder(QueryBuilder $qb, $expectedDql) |
39 | 42 | { |
40 | 43 | $dql = $qb->getDQL(); |
@@ -48,6 +48,9 @@ discard block |
||
48 | 48 | return EntityManagerMock::create($conn, $config, $eventManager); |
49 | 49 | } |
50 | 50 | |
51 | + /** |
|
52 | + * @param string $path |
|
53 | + */ |
|
51 | 54 | protected function _createMetadataDriver($type, $path) |
52 | 55 | { |
53 | 56 | $mappingDriver = [ |
@@ -67,6 +70,9 @@ discard block |
||
67 | 70 | return $driver; |
68 | 71 | } |
69 | 72 | |
73 | + /** |
|
74 | + * @param EntityManagerMock $em |
|
75 | + */ |
|
70 | 76 | protected function _createClassMetadataFactory($em, $type) |
71 | 77 | { |
72 | 78 | $factory = ($type === 'annotation') |
@@ -277,7 +283,6 @@ discard block |
||
277 | 283 | |
278 | 284 | /** |
279 | 285 | * @depends testOneToManyAssociationsAreExported |
280 | - * @param ClassMetadataInfo $metadata |
|
281 | 286 | */ |
282 | 287 | public function testManyToManyAssociationsAreExported($class) |
283 | 288 | { |
@@ -376,6 +381,9 @@ discard block |
||
376 | 381 | # $this->_deleteDirectory(__DIR__ . '/export/'.$this->_getType()); |
377 | 382 | } |
378 | 383 | |
384 | + /** |
|
385 | + * @param string $path |
|
386 | + */ |
|
379 | 387 | protected function _deleteDirectory($path) |
380 | 388 | { |
381 | 389 | if (is_file($path)) { |