You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2019/10/20 14:51:42 UTC

[GitHub] [incubator-shardingsphere] terrymanu commented on a change in pull request #3333: #3138 improved coverage for sharding-core-preprocessor

terrymanu commented on a change in pull request #3333: #3138 improved coverage for sharding-core-preprocessor
URL: https://github.com/apache/incubator-shardingsphere/pull/3333#discussion_r336782042
 
 

 ##########
 File path: sharding-core/sharding-core-preprocessor/src/test/java/org/apache/shardingsphere/core/preprocessor/segment/select/projection/engine/ProjectionEngineTest.java
 ##########
 @@ -91,4 +91,20 @@ public void assertProjectionCreatedWhenSelectItemSegmentInstanceOfAggregationSel
         assertThat(projection.get(), instanceOf(AggregationProjection.class));
     }
     
+    @Test
+    public void assertProjectionCreatedWhenSelectItemSegmentInstanceOfAggregationDistinctSelectItemSegmentAndAggregationTypeIsAvg() {
+        AggregationDistinctSelectItemSegment aggregationDistinctSelectItemSegment = new AggregationDistinctSelectItemSegment(0, 10, "text", AggregationType.AVG, 0, "distinctExpression");
+        Optional<Projection> projection = new ProjectionEngine().createProjection("select count(1) from table_1", aggregationDistinctSelectItemSegment);
+        assertTrue(projection.isPresent());
+        assertThat(projection.get(), instanceOf(AggregationDistinctProjection.class));
+    }
+    
+    @Test
+    public void assertProjectionCreatedWhenSelectItemSegmentInstanceOfAggregationSelectItemSegmentAndAggregationTypeIsAvg() {
 
 Review comment:
   This method name is not follow test case's conduct

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services