From commits-return-3801-apmail-drill-commits-archive=drill.apache.org@drill.apache.org Tue Feb 9 00:26:53 2016 Return-Path: X-Original-To: apmail-drill-commits-archive@www.apache.org Delivered-To: apmail-drill-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 97E2618233 for ; Tue, 9 Feb 2016 00:26:52 +0000 (UTC) Received: (qmail 21756 invoked by uid 500); 9 Feb 2016 00:26:52 -0000 Delivered-To: apmail-drill-commits-archive@drill.apache.org Received: (qmail 21688 invoked by uid 500); 9 Feb 2016 00:26:52 -0000 Mailing-List: contact commits-help@drill.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: commits@drill.apache.org Delivered-To: mailing list commits@drill.apache.org Received: (qmail 21565 invoked by uid 99); 9 Feb 2016 00:26:52 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 09 Feb 2016 00:26:52 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 4A2FFE6989; Tue, 9 Feb 2016 00:26:52 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: json@apache.org To: commits@drill.apache.org Date: Tue, 09 Feb 2016 00:26:58 -0000 Message-Id: In-Reply-To: <0e099b992bb64183a0ab11c9e8b5bcde@git.apache.org> References: <0e099b992bb64183a0ab11c9e8b5bcde@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [7/8] drill git commit: DRILL-4331: Fix TestFlattenPlanning.testFlattenPlanningAvoidUnnecessaryProject test for Java8 DRILL-4331: Fix TestFlattenPlanning.testFlattenPlanningAvoidUnnecessaryProject test for Java8 Test TestFlattenPlanning.testFlattenPlanningAvoidUnnecessaryProject fails with Java8 because of Map order differences between Java7 and Java8. Test now checks for both options. Closes #351 Project: http://git-wip-us.apache.org/repos/asf/drill/repo Commit: http://git-wip-us.apache.org/repos/asf/drill/commit/32da4675 Tree: http://git-wip-us.apache.org/repos/asf/drill/tree/32da4675 Diff: http://git-wip-us.apache.org/repos/asf/drill/diff/32da4675 Branch: refs/heads/master Commit: 32da4675e8bf1358b863532daadd2769f380600f Parents: fbb0165 Author: Laurent Goujon Authored: Mon Feb 1 11:06:01 2016 -0800 Committer: Jason Altekruse Committed: Mon Feb 8 14:56:16 2016 -0800 ---------------------------------------------------------------------- .../drill/exec/physical/impl/flatten/TestFlattenPlanning.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/drill/blob/32da4675/exec/java-exec/src/test/java/org/apache/drill/exec/physical/impl/flatten/TestFlattenPlanning.java ---------------------------------------------------------------------- diff --git a/exec/java-exec/src/test/java/org/apache/drill/exec/physical/impl/flatten/TestFlattenPlanning.java b/exec/java-exec/src/test/java/org/apache/drill/exec/physical/impl/flatten/TestFlattenPlanning.java index a6e4786..f32eaaa 100644 --- a/exec/java-exec/src/test/java/org/apache/drill/exec/physical/impl/flatten/TestFlattenPlanning.java +++ b/exec/java-exec/src/test/java/org/apache/drill/exec/physical/impl/flatten/TestFlattenPlanning.java @@ -24,8 +24,11 @@ public class TestFlattenPlanning extends PlanTestBase { @Test public void testFlattenPlanningAvoidUnnecessaryProject() throws Exception { - testPlanSubstrPatterns("select flatten(complex), rownum from cp.`/store/json/test_flatten_mappify2.json`", - new String[]{"Project(EXPR$0=[$1], rownum=[$0])"}, new String[]{"Project(EXPR$0=[$0], EXPR$1=[$1], EXPR$3=[$1])"}); + // Because of Java7 vs Java8 map ordering differences, we check for both cases + // See DRILL-4331 for details + testPlanMatchingPatterns("select flatten(complex), rownum from cp.`/store/json/test_flatten_mappify2.json`", + new String[]{"\\QProject(EXPR$0=[$1], rownum=[$0])\\E|\\QProject(EXPR$0=[$0], rownum=[$1])\\E"}, + new String[]{"\\QProject(EXPR$0=[$0], EXPR$1=[$1], EXPR$3=[$1])\\E|\\QProject(EXPR$0=[$1], EXPR$1=[$0], EXPR$3=[$0])\\E"}); } @Test // DRILL-4121 : push partial filter past projects.