@Test
public void getHashedIndexDBObjectTest() throws MongoValidationException {

    IndexMetadataBuilder indexMetaBuilder = new IndexMetadataBuilder(DB_NAME, TABLE_NAME, INDEX_NAME,
                    IndexType.CUSTOM);
    indexMetaBuilder.addColumn(COLUMN_NAME, COLUMN_VARCHAR);
    indexMetaBuilder.addOption(IndexOptions.INDEX_TYPE.getOptionName(), CustomMongoIndexType.HASHED.getIndexType());
    IndexMetadata indexMetadata = indexMetaBuilder.build();
    DBObject object = IndexUtils.getIndexDBObject(indexMetadata);
    assertEquals("The value of the hashed index column should be 'hashed'", "hashed", object.get(COLUMN_NAME));
}