yanxinyi commented on a change in pull request #830:
URL: https://github.com/apache/phoenix/pull/830#discussion_r455503788
##########
File path:
phoenix-core/src/test/java/org/apache/phoenix/compile/RVCOffsetCompilerTest.java
##########
@@ -148,12 +153,82 @@ public void buildListOfRowKeyColumnExpressionsIndexTest()
throws Exception {
expressions.add(expression1);
expressions.add(expression2);
+ AndExpression expression = mock(AndExpression.class);
+ Mockito.when(expression.getChildren()).thenReturn(expressions);
+
+ List<RowKeyColumnExpression>
+ result =
+ offsetCompiler.buildListOfRowKeyColumnExpressions(expression,
true);
+
+ assertEquals(2,result.size());
+ assertEquals(rvc1,result.get(0));
+ assertEquals(rvc2,result.get(1));
+ }
+
+ @Test
+ public void buildListOfRowKeyColumnExpressionsSingleNodeComparisonTest()
throws Exception {
+ List<Expression> expressions = new ArrayList<>();
+
+ RowKeyColumnExpression rvc1 = new RowKeyColumnExpression();
+ RowKeyColumnExpression rvc2 = new RowKeyColumnExpression();
Review comment:
remove unused expression rvc2?
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]