Code Duplication    Length = 10-10 lines in 2 locations

tests/Doctrine/Tests/ORM/Functional/EntityRepositoryTest.php 2 locations

@@ 450-459 (lines=10) @@
447
    /**
448
     * @group DDC-817
449
     */
450
    public function testFindByAssociationKey()
451
    {
452
        list($userId, $addressId) = $this->loadAssociatedFixture();
453
        $repos = $this->em->getRepository(CmsAddress::class);
454
        $addresses = $repos->findBy(['user' => $userId]);
455
456
        self::assertContainsOnly(CmsAddress::class, $addresses);
457
        self::assertEquals(1, count($addresses));
458
        self::assertEquals($addressId, $addresses[0]->id);
459
    }
460
461
    /**
462
     * @group DDC-817
@@ 464-473 (lines=10) @@
461
    /**
462
     * @group DDC-817
463
     */
464
    public function testFindAssociationByMagicCall()
465
    {
466
        list($userId, $addressId) = $this->loadAssociatedFixture();
467
        $repos = $this->em->getRepository(CmsAddress::class);
468
        $addresses = $repos->findByUser($userId);
469
470
        self::assertContainsOnly(CmsAddress::class, $addresses);
471
        self::assertEquals(1, count($addresses));
472
        self::assertEquals($addressId, $addresses[0]->id);
473
    }
474
475
    /**
476
     * @group DDC-817