jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mreut...@apache.org
Subject svn commit: r428306 - in /jackrabbit/trunk/jackrabbit/src/test/java/org/apache/jackrabbit/test/api/query: AbstractQueryTest.java XPathOrderByTest.java
Date Thu, 03 Aug 2006 10:28:38 GMT
Author: mreutegg
Date: Thu Aug  3 03:28:32 2006
New Revision: 428306

URL: http://svn.apache.org/viewvc?rev=428306&view=rev
Log:
JCR-518: TCK: XPath order by test uses non-standard column specifier mechanism

Modified:
    jackrabbit/trunk/jackrabbit/src/test/java/org/apache/jackrabbit/test/api/query/AbstractQueryTest.java
    jackrabbit/trunk/jackrabbit/src/test/java/org/apache/jackrabbit/test/api/query/XPathOrderByTest.java

Modified: jackrabbit/trunk/jackrabbit/src/test/java/org/apache/jackrabbit/test/api/query/AbstractQueryTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit/src/test/java/org/apache/jackrabbit/test/api/query/AbstractQueryTest.java?rev=428306&r1=428305&r2=428306&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit/src/test/java/org/apache/jackrabbit/test/api/query/AbstractQueryTest.java
(original)
+++ jackrabbit/trunk/jackrabbit/src/test/java/org/apache/jackrabbit/test/api/query/AbstractQueryTest.java
Thu Aug  3 03:28:32 2006
@@ -205,16 +205,16 @@
     protected void evaluateResultOrder(QueryResult queryResult, String propName,
                                        boolean descending)
             throws RepositoryException, NotExecutableException {
-        RowIterator rows = queryResult.getRows();
-        if (getSize(rows) < 2) {
+        NodeIterator nodes = queryResult.getNodes();
+        if (getSize(nodes) < 2) {
             fail("Workspace does not contain sufficient content to test ordering on result
nodes.");
         }
-        // need to re-aquire rows, {@link #getSize} may consume elements.
-        rows = queryResult.getRows();
+        // need to re-aquire nodes, {@link #getSize} may consume elements.
+        nodes = queryResult.getNodes();
         int changeCnt = 0;
         String last = descending ? "\uFFFF" : "";
-        while (rows.hasNext()) {
-            String value = rows.nextRow().getValue(propName).getString();
+        while (nodes.hasNext()) {
+            String value = nodes.nextNode().getProperty(propName).getString();
             int cp = value.compareTo(last);
             // if value changed evaluate if the ordering is correct
             if (cp != 0) {

Modified: jackrabbit/trunk/jackrabbit/src/test/java/org/apache/jackrabbit/test/api/query/XPathOrderByTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit/src/test/java/org/apache/jackrabbit/test/api/query/XPathOrderByTest.java?rev=428306&r1=428305&r2=428306&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit/src/test/java/org/apache/jackrabbit/test/api/query/XPathOrderByTest.java
(original)
+++ jackrabbit/trunk/jackrabbit/src/test/java/org/apache/jackrabbit/test/api/query/XPathOrderByTest.java
Thu Aug  3 03:28:32 2006
@@ -48,7 +48,7 @@
         tmp.append(jcrRoot).append(testRoot);
         tmp.append("/*[@");
         tmp.append(propertyName1);
-        tmp.append("]/@").append(propertyName1).append(" order by @");
+        tmp.append("] order by @");
         tmp.append(propertyName1);
         baseStatement = tmp.toString();
     }



Mime
View raw message