# 关联数组集合 collection
Testing Is Documentation
Uses
<?php
use Leevel\Support\TypedAssociativeArray;
# 基本使用
public function testBaseUse(): void
{
$data = [
'h' => 'hello',
'w' => 'world',
];
$collection = new TypedAssociativeArray($data);
$this->assertSame($collection['h'], 'hello');
$this->assertSame($collection['w'], 'world');
$this->assertTrue(isset($collection['h']));
$this->assertTrue(isset($collection['w']));
}