From 206f0f04e1d6d28b7a1a8c7166bf7e5e366b5dde Mon Sep 17 00:00:00 2001 From: Patrick Linskey Date: Wed, 16 Jan 2008 04:35:26 +0000 Subject: [PATCH] OPENJPA-488, OPENJPA-489, OPENJPA-490, OPENJPA-491, OPENJPA-492. Reduce logging in test case; use onlyChild() to validate tree structure. git-svn-id: https://svn.apache.org/repos/asf/openjpa/trunk@612348 13f79535-47bb-0310-9956-ffa450edef68 --- .../apache/openjpa/kernel/jpql/JPQLExpressionBuilder.java | 6 +++--- .../apache/openjpa/persistence/query/GroupingTestCase.java | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/openjpa-kernel/src/main/java/org/apache/openjpa/kernel/jpql/JPQLExpressionBuilder.java b/openjpa-kernel/src/main/java/org/apache/openjpa/kernel/jpql/JPQLExpressionBuilder.java index 84a17b38b..0f7883865 100644 --- a/openjpa-kernel/src/main/java/org/apache/openjpa/kernel/jpql/JPQLExpressionBuilder.java +++ b/openjpa-kernel/src/main/java/org/apache/openjpa/kernel/jpql/JPQLExpressionBuilder.java @@ -1075,13 +1075,13 @@ public class JPQLExpressionBuilder return factory.getCurrentTimestamp(); case JJTSELECTEXTENSION: - return eval(node.children[0]); + return eval(onlyChild(node)); case JJTGROUPBYEXTENSION: - return eval(node.children[0]); + return eval(onlyChild(node)); case JJTORDERBYEXTENSION: - return eval(node.children[0]); + return eval(onlyChild(node)); default: throw parseException(EX_FATAL, "bad-tree", diff --git a/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/query/GroupingTestCase.java b/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/query/GroupingTestCase.java index 2178d5c50..aa62d5393 100644 --- a/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/query/GroupingTestCase.java +++ b/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/query/GroupingTestCase.java @@ -38,7 +38,7 @@ public abstract class GroupingTestCase protected abstract void prepareQuery(Query q); public void setUp() { - super.setUp(AllFieldTypes.class, CLEAR_TABLES, "openjpa.Log", "SQL=TRACE"); + super.setUp(AllFieldTypes.class, CLEAR_TABLES); AllFieldTypes pc1 = new AllFieldTypes(); AllFieldTypes pc2 = new AllFieldTypes();