Code Duplication    Length = 9-11 lines in 2 locations

tests/unit/Flow/FlowCollectionTest.php 2 locations

@@ 33-41 (lines=9) @@
30
        static::assertInstanceOf(IteratorAggregate::class, $collection);
31
    }
32
33
    public function testConstructWithMultipleFlows()
34
    {
35
        $flow1 = m::mock(FlowInterface::class);
36
        $flow2 = m::mock(FlowInterface::class);
37
38
        $collection = new FlowCollection($flow1, $flow2);
39
40
        static::assertEquals([$flow1, $flow2], $collection->getAll());
41
    }
42
43
    public function testAddWillAppendTheFlow()
44
    {
@@ 109-119 (lines=11) @@
106
        static::assertEquals(1, $collection->count());
107
    }
108
109
    public function testIterator()
110
    {
111
        $flow1 = m::mock(FlowInterface::class);
112
        $flow2 = m::mock(FlowInterface::class);
113
114
        $collection = new FlowCollection($flow1, $flow2);
115
116
        foreach ($collection->getIterator() as $flow) {
117
            static::assertContains($flow, [$flow1, $flow2]);
118
        }
119
    }
120
121
    public function testSerialize()
122
    {