From bfa7d2c69629d764beefe61312343372376040d4 Mon Sep 17 00:00:00 2001
From: "Richard G. Curtis" <curtisr7@apache.org>
Date: Mon, 29 Oct 2012 19:59:19 +0000
Subject: [PATCH] OPENJPA-2280: Update testcase so it works on DB2.

git-svn-id: https://svn.apache.org/repos/asf/openjpa/trunk@1403472 13f79535-47bb-0310-9956-ffa450edef68
---
 .../openjpa/persistence/criteria/AbstractCriteriaTestCase.java | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/criteria/AbstractCriteriaTestCase.java b/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/criteria/AbstractCriteriaTestCase.java
index 77dd8dba7..a4149902d 100644
--- a/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/criteria/AbstractCriteriaTestCase.java
+++ b/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/criteria/AbstractCriteriaTestCase.java
@@ -34,6 +34,7 @@ import javax.persistence.criteria.CriteriaQuery;
 import junit.framework.TestCase;
 
 import org.apache.openjpa.jdbc.conf.JDBCConfiguration;
+import org.apache.openjpa.jdbc.sql.AbstractDB2Dictionary;
 import org.apache.openjpa.jdbc.sql.DBDictionary;
 import org.apache.openjpa.jdbc.sql.DerbyDictionary;
 import org.apache.openjpa.jdbc.sql.HSQLDictionary;
@@ -104,7 +105,7 @@ public abstract class AbstractCriteriaTestCase extends TestCase {
     void setDictionary() {
         JDBCConfiguration conf = (JDBCConfiguration) getEntityManagerFactory().getConfiguration();
         dict = conf.getDBDictionaryInstance();
-        if (dict instanceof DerbyDictionary || dict instanceof HSQLDictionary) {
+        if (dict instanceof AbstractDB2Dictionary || dict instanceof HSQLDictionary) {
             dict.requiresCastForComparisons = false;
             dict.requiresCastForMathFunctions = false;
         } else if (dict instanceof OracleDictionary) {