impala-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ph...@apache.org
Subject [2/5] impala git commit: IMPALA-6427: fix QUERYOPTIONS in planner test output
Date Tue, 23 Jan 2018 00:42:45 GMT
IMPALA-6427: fix QUERYOPTIONS in planner test output

Testing:
Ran planner tests. Confirmed that the generated union.test
included the QUERYOPTIONS section and that test files without the
QUERYOPTIONS section did not have QUERYOPTIONS sections added.

Change-Id: I2971588f977f72b0f869370803b089d56303d91a
Reviewed-on: http://gerrit.cloudera.org:8080/9081
Reviewed-by: Alex Behm <alex.behm@cloudera.com>
Tested-by: Impala Public Jenkins


Project: http://git-wip-us.apache.org/repos/asf/impala/repo
Commit: http://git-wip-us.apache.org/repos/asf/impala/commit/e376d333
Tree: http://git-wip-us.apache.org/repos/asf/impala/tree/e376d333
Diff: http://git-wip-us.apache.org/repos/asf/impala/diff/e376d333

Branch: refs/heads/2.x
Commit: e376d333c9f1a78fddbe9c5c2de718fb9d8bf0a6
Parents: 8f0ef09
Author: Tim Armstrong <tarmstrong@cloudera.com>
Authored: Fri Jan 19 12:22:18 2018 -0800
Committer: Philip Zeyliger <philip@cloudera.com>
Committed: Mon Jan 22 16:41:16 2018 -0800

----------------------------------------------------------------------
 .../test/java/org/apache/impala/planner/PlannerTestBase.java | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/impala/blob/e376d333/fe/src/test/java/org/apache/impala/planner/PlannerTestBase.java
----------------------------------------------------------------------
diff --git a/fe/src/test/java/org/apache/impala/planner/PlannerTestBase.java b/fe/src/test/java/org/apache/impala/planner/PlannerTestBase.java
index ab538ff..bc93160 100644
--- a/fe/src/test/java/org/apache/impala/planner/PlannerTestBase.java
+++ b/fe/src/test/java/org/apache/impala/planner/PlannerTestBase.java
@@ -19,7 +19,6 @@ package org.apache.impala.planner;
 
 import static org.junit.Assert.fail;
 
-import java.io.File;
 import java.io.FileWriter;
 import java.io.IOException;
 import java.nio.file.Paths;
@@ -745,6 +744,13 @@ public class PlannerTestBase extends FrontendTestBase {
     for (TestCase testCase : queryFileParser.getTestCases()) {
       actualOutput.append(testCase.getSectionAsString(Section.QUERY, true, "\n"));
       actualOutput.append("\n");
+      String queryOptionsSection = testCase.getSectionAsString(
+          Section.QUERYOPTIONS, true, "\n");
+      if (queryOptionsSection != null && !queryOptionsSection.isEmpty()) {
+        actualOutput.append("---- QUERYOPTIONS\n");
+        actualOutput.append(queryOptionsSection);
+        actualOutput.append("\n");
+      }
       try {
         runTestCase(testCase, errorLog, actualOutput, dbName, ignoreExplainHeader);
       } catch (CatalogException e) {


Mime
View raw message