Cassandra\SchemaMetadataIntegrationTest::testCollectionSecondaryIndexes PHP Method

testCollectionSecondaryIndexes() public method

This test ensures that secondary indexes are properly handled by the driver.
    public function testCollectionSecondaryIndexes()
    {
        // Create the table and secondary index
        $this->createTableForSecondaryIndexes();
        $this->createCollectionSecondaryIndex();
        // Validate the schema metadata
        $table = $this->session->schema()->keyspace($this->keyspaceName)->table($this->tableNamePrefix);
        $this->assertCount(1, $table->indexes());
        $index = $table->index("collection");
        $this->assertIndex($index, "composites", "keys(value2)", false, false);
    }