Skip to content

Commit

Permalink
resolve merge conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
Michael Sokolov committed Sep 20, 2024
1 parent 2a284f2 commit cb62025
Showing 1 changed file with 12 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1882,25 +1882,27 @@ public void testMismatchedFields() throws Exception {

ByteVectorValues byteVectors = leafReader.getByteVectorValues("byte");
assertNotNull(byteVectors);
assertEquals(0, byteVectors.nextDoc());
assertArrayEquals(new byte[] {42}, byteVectors.vectorValue());
assertEquals(1, byteVectors.nextDoc());
assertArrayEquals(new byte[] {42}, byteVectors.vectorValue());
assertEquals(DocIdSetIterator.NO_MORE_DOCS, byteVectors.nextDoc());
KnnVectorValues.DocIndexIterator iter = byteVectors.iterator();
assertEquals(0, iter.nextDoc());
assertArrayEquals(new byte[] {42}, byteVectors.vectorValue(0));
assertEquals(1, iter.nextDoc());
assertArrayEquals(new byte[] {42}, byteVectors.vectorValue(1));
assertEquals(DocIdSetIterator.NO_MORE_DOCS, iter.nextDoc());

FloatVectorValues floatVectors = leafReader.getFloatVectorValues("float");
assertNotNull(floatVectors);
assertEquals(0, floatVectors.nextDoc());
float[] vector = floatVectors.vectorValue();
iter = floatVectors.iterator();
assertEquals(0, iter.nextDoc());
float[] vector = floatVectors.vectorValue(0);
assertEquals(2, vector.length);
assertEquals(1f, vector[0], 0f);
assertEquals(2f, vector[1], 0f);
assertEquals(1, floatVectors.nextDoc());
vector = floatVectors.vectorValue();
assertEquals(1, iter.nextDoc());
vector = floatVectors.vectorValue(1);
assertEquals(2, vector.length);
assertEquals(1f, vector[0], 0f);
assertEquals(2f, vector[1], 0f);
assertEquals(DocIdSetIterator.NO_MORE_DOCS, floatVectors.nextDoc());
assertEquals(DocIdSetIterator.NO_MORE_DOCS, iter.nextDoc());

IOUtils.close(reader, w2, dir1, dir2);
}
Expand Down

0 comments on commit cb62025

Please sign in to comment.