function testKeysMap() { $array = ['one' => 1, 'two' => 2, 'three' => 3]; $iterator = new IteratorCollectionAdapter(new ArrayIterator($array)); $this->assertEquals(['one', 'two', 'three'], $iterator->keys()->toArray()); }