vibhatha commented on code in PR #41636:
URL: https://github.com/apache/arrow/pull/41636#discussion_r1600791193
##########
java/vector/src/test/java/org/apache/arrow/vector/compare/TestRangeEqualsVisitor.java:
##########
@@ -132,6 +136,24 @@ public void testBaseVariableVectorRangeEquals() {
}
}
+ @Test
+ public void testBaseVariableViewVectorRangeEquals() {
+ try (final ViewVarCharVector vector1 = new ViewVarCharVector("varchar",
allocator);
+ final ViewVarCharVector vector2 = new ViewVarCharVector("varchar",
allocator)) {
+
+ setVector(vector1, STR1, STR2, STR4, STR3, STR2, STR5, STR1, STR6);
+ setVector(vector2, STR1, STR2, STR4, STR3, STR2, STR5, STR1, STR6);
+
+ RangeEqualsVisitor visitor = new RangeEqualsVisitor(vector1, vector2);
+ // inclusion of long string in the middle
+ assertTrue(visitor.rangeEquals(new Range(1, 1, 3)));
+ // inclusion of long string at the start
+ assertTrue(visitor.rangeEquals(new Range(2, 2, 4)));
+ // inclusion of long string at the end
+ assertTrue(visitor.rangeEquals(new Range(4, 4, 4)));
Review Comment:
I added one case for that.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]