make existing tests pass and add tests for secondaryIndex options