jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mreut...@apache.org
Subject svn commit: r169464 - /incubator/jackrabbit/trunk/src/test/org/apache/jackrabbit/test/api/query/OrderByMultiTypeTest.java
Date Tue, 10 May 2005 13:07:02 GMT
Author: mreutegg
Date: Tue May 10 06:07:02 2005
New Revision: 169464

URL: http://svn.apache.org/viewcvs?rev=169464&view=rev
Log:
Fix test case. SQL is optional feature and must not be tested if not supported.

Modified:
    incubator/jackrabbit/trunk/src/test/org/apache/jackrabbit/test/api/query/OrderByMultiTypeTest.java

Modified: incubator/jackrabbit/trunk/src/test/org/apache/jackrabbit/test/api/query/OrderByMultiTypeTest.java
URL: http://svn.apache.org/viewcvs/incubator/jackrabbit/trunk/src/test/org/apache/jackrabbit/test/api/query/OrderByMultiTypeTest.java?rev=169464&r1=169463&r2=169464&view=diff
==============================================================================
--- incubator/jackrabbit/trunk/src/test/org/apache/jackrabbit/test/api/query/OrderByMultiTypeTest.java
(original)
+++ incubator/jackrabbit/trunk/src/test/org/apache/jackrabbit/test/api/query/OrderByMultiTypeTest.java
Tue May 10 06:07:02 2005
@@ -78,9 +78,11 @@
                 jcrPath + " LIKE '" + testRoot + "/%' ORDER BY " +
                 propertyName2 + " DESC, " +
                 propertyName1 + " DESC";
-        q = superuser.getWorkspace().getQueryManager().createQuery(sql, Query.SQL);
-        result = q.execute();
-        checkResultOrder(result, new String[]{nodeName1, nodeName3, nodeName2});
+        if (checkSQL) {
+            q = superuser.getWorkspace().getQueryManager().createQuery(sql, Query.SQL);
+            result = q.execute();
+            checkResultOrder(result, new String[]{nodeName1, nodeName3, nodeName2});
+        }
 
         xpath = "/" + jcrRoot + testRoot + "/*[@" + jcrPrimaryType + "='" +
                 testNodeType + "'] order by @" +
@@ -94,9 +96,11 @@
         sql = "SELECT " + propertyName2 + " FROM " + testNodeType + " WHERE " +
                 jcrPath + " LIKE '" + testRoot + "/%' ORDER BY " +
                 propertyName2 + " DESC, " + propertyName1;
-        q = superuser.getWorkspace().getQueryManager().createQuery(sql, Query.SQL);
-        result = q.execute();
-        checkResultOrder(result, new String[]{nodeName1, nodeName2, nodeName3});
+        if (checkSQL) {
+            q = superuser.getWorkspace().getQueryManager().createQuery(sql, Query.SQL);
+            result = q.execute();
+            checkResultOrder(result, new String[]{nodeName1, nodeName2, nodeName3});
+        }
 
         xpath = "/" + jcrRoot + testRoot + "/*[@" + jcrPrimaryType + "='" +
                 testNodeType + "'] order by @" + propertyName2 +



Mime
View raw message