public function testIteratorSecondaryIndexes()
{
// Create the table and secondary indexes
$this->createTableForSecondaryIndexes();
$this->createSimpleSecondaryIndex();
$this->createCollectionSecondaryIndex();
// Validate the schema metadata
$table = $this->session->schema()->keyspace($this->keyspaceName)->table($this->tableNamePrefix);
$indexes = $table->indexes();
$this->assertCount(2, $indexes);
foreach ($indexes as $index) {
$this->assertTrue($index->name() == "simple" || $index->name() == "collection");
}
}