Test PositionIndexer

Added tests for `PositionIndexer` in `PositionIndexerTest` and fixed a spelling error in javadoc in `PositionIndexer`.