jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From resc...@apache.org
Subject svn commit: r527970 - /jackrabbit/trunk/jackrabbit-jcr-tests/src/main/java/org/apache/jackrabbit/test/api/SetPropertyInputStreamTest.java
Date Thu, 12 Apr 2007 15:07:15 GMT
Author: reschke
Date: Thu Apr 12 08:07:13 2007
New Revision: 527970

URL: http://svn.apache.org/viewvc?view=rev&rev=527970
Log:
JCR-830: allow tests to run with repositories that do support binary properties only on automatically
created child nodes of type nt:resource.

Modified:
    jackrabbit/trunk/jackrabbit-jcr-tests/src/main/java/org/apache/jackrabbit/test/api/SetPropertyInputStreamTest.java

Modified: jackrabbit/trunk/jackrabbit-jcr-tests/src/main/java/org/apache/jackrabbit/test/api/SetPropertyInputStreamTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-jcr-tests/src/main/java/org/apache/jackrabbit/test/api/SetPropertyInputStreamTest.java?view=diff&rev=527970&r1=527969&r2=527970
==============================================================================
--- jackrabbit/trunk/jackrabbit-jcr-tests/src/main/java/org/apache/jackrabbit/test/api/SetPropertyInputStreamTest.java
(original)
+++ jackrabbit/trunk/jackrabbit-jcr-tests/src/main/java/org/apache/jackrabbit/test/api/SetPropertyInputStreamTest.java
Thu Apr 12 08:07:13 2007
@@ -44,6 +44,14 @@
     protected void setUp() throws Exception {
         super.setUp();
         testNode = testRootNode.addNode(nodeName1, testNodeType);
+        testRootNode.save();
+        
+        // special case for repositories that do allow binary property
+        // values, but only on jcr:content/jcr:data
+        if (propertyName1.equals("jcr:data") && testNode.hasNode("jcr:content")
+            && testNode.getNode("jcr:content").isNodeType("nt:resource") &&
! testNode.hasProperty("jcr:data")) {
+          testNode = testNode.getNode("jcr:content");
+        }
     }
 
     /**



Mime
View raw message