jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Pitfield (JIRA)" <j...@apache.org>
Subject [jira] Created: (JCR-525) TCK: TextNodeTest and jcr:xmltext/jcr:xmlcharacters
Date Mon, 31 Jul 2006 18:14:13 GMT
TCK: TextNodeTest and jcr:xmltext/jcr:xmlcharacters
---------------------------------------------------

                 Key: JCR-525
                 URL: http://issues.apache.org/jira/browse/JCR-525
             Project: Jackrabbit
          Issue Type: Bug
          Components: test
            Reporter: David Pitfield


Test creates jcr:xmltext nodes without jcr:xmlcharacters properties.  Some repositories may
require jcr:xmltext nodes to have jcr:xmlcharacters properties, causing this test to fail.

Proposal: add a jcr:xmlcharacters property to each jcr:xmltext node.

--- TextNodeTest.java   (revision 422074)
+++ TextNodeTest.java   (working copy)
@@ -62,6 +62,7 @@
      */
     public void testTextNodeTest() throws RepositoryException {
         Node text1 = testRootNode.addNode(jcrXMLText);
+        text1.setProperty(jcrXMLCharacters, "foo");
         testRootNode.save();
         String xpath = "/" + jcrRoot + testRoot + "/text()";
         executeXPathQuery(superuser, xpath, new Node[]{text1});
@@ -73,7 +74,9 @@
      */
     public void testTextNodeTestMultiNodes() throws RepositoryException {
         Node text1 = testRootNode.addNode(jcrXMLText);
+        text1.setProperty(jcrXMLCharacters, "foo");
         Node text2 = testRootNode.addNode(nodeName1, testNodeType).addNode(jcrXMLText);
+        text2.setProperty(jcrXMLCharacters, "foo");
         testRootNode.save();
         String xpath = "/" + jcrRoot + testRoot + "//text()";
         executeXPathQuery(superuser, xpath, new Node[]{text1, text2});
@@ -105,11 +108,13 @@
             throw new NotExecutableException("Repository does not support position index");
         }
         Node text1 = testRootNode.addNode(jcrXMLText);
+        text1.setProperty(jcrXMLCharacters, "foo");
         if (!text1.getDefinition().allowsSameNameSiblings()) {
             throw new NotExecutableException("Node at path: " + testRoot + " does not allow
same name siblings with name: " + jcrXMLText);
         }
         testRootNode.addNode(nodeName1, testNodeType);
         Node text2 = testRootNode.addNode(jcrXMLText);
+        text1.setProperty(jcrXMLCharacters, "foo");
         testRootNode.save();
         String xpath = "/" + jcrRoot + testRoot + "/text()[2]";
         executeXPathQuery(superuser, xpath, new Node[]{text2});


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message