Code Duplication    Length = 15-15 lines in 2 locations

Tests/Functional/MappingToElasticaTest.php 1 location

@@ 88-102 (lines=15) @@
85
        $this->assertNotEmpty($mapping, 'Mapping was populated');
86
    }
87
88
    public function testMappingIteratorToArrayField()
89
    {
90
        $client = $this->createClient(array('test_case' => 'ORM'));
91
        $persister = $client->getContainer()->get('fos_elastica.object_persister.index.type');
92
93
        $object = new TypeObj();
94
        $object->id = 1;
95
        $object->coll = new \ArrayIterator(array('foo', 'bar'));
96
        $persister->insertOne($object);
97
98
        $object->coll = new \ArrayIterator(array('foo', 'bar', 'bazz'));
99
        $object->coll->offsetUnset(1);
100
101
        $persister->replaceOne($object);
102
    }
103
104
    /**
105
     * @param Client $client

Tests/Functional/SerializerTest.php 1 location

@@ 19-33 (lines=15) @@
16
 */
17
class SerializerTest extends WebTestCase
18
{
19
    public function testMappingIteratorToArrayField()
20
    {
21
        $client = $this->createClient(array('test_case' => 'Serializer'));
22
        $persister = $client->getContainer()->get('fos_elastica.object_persister.index.type');
23
24
        $object = new TypeObj();
25
        $object->id = 1;
26
        $object->coll = new \ArrayIterator(array('foo', 'bar'));
27
        $persister->insertOne($object);
28
29
        $object->coll = new \ArrayIterator(array('foo', 'bar', 'bazz'));
30
        $object->coll->offsetUnset(1);
31
32
        $persister->replaceOne($object);
33
    }
34
35
    public function testUnmappedType()
36
    {