jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mreut...@apache.org
Subject svn commit: r209050 - in /incubator/jackrabbit/trunk/core/src/test/org/apache/jackrabbit/test/api/version: VersionHistoryTest.java VersionTest.java
Date Mon, 04 Jul 2005 09:45:46 GMT
Author: mreutegg
Date: Mon Jul  4 02:45:45 2005
New Revision: 209050

URL: http://svn.apache.org/viewcvs?rev=209050&view=rev
Log:
JCR-156: Review test cases and cross check with 1.0 specification
- Remove invalid test cases.

Modified:
    incubator/jackrabbit/trunk/core/src/test/org/apache/jackrabbit/test/api/version/VersionHistoryTest.java
    incubator/jackrabbit/trunk/core/src/test/org/apache/jackrabbit/test/api/version/VersionTest.java

Modified: incubator/jackrabbit/trunk/core/src/test/org/apache/jackrabbit/test/api/version/VersionHistoryTest.java
URL: http://svn.apache.org/viewcvs/incubator/jackrabbit/trunk/core/src/test/org/apache/jackrabbit/test/api/version/VersionHistoryTest.java?rev=209050&r1=209049&r2=209050&view=diff
==============================================================================
--- incubator/jackrabbit/trunk/core/src/test/org/apache/jackrabbit/test/api/version/VersionHistoryTest.java
(original)
+++ incubator/jackrabbit/trunk/core/src/test/org/apache/jackrabbit/test/api/version/VersionHistoryTest.java
Mon Jul  4 02:45:45 2005
@@ -98,32 +98,6 @@
     }
 
     /**
-     * Test if initially auto-created root version does not provide any state
-     * information
-     */
-    public void testAutocreatedRootVersionHasNoState() throws
-            RepositoryException {
-
-        /*
-
-        the spec 1.0 does not properly define this anymore. the
-        nt:version does not have a jcr:frozenUUID or jcr:primaryType, this was
-        moved to nt:frozenNode. so, the jcr:rootVersion is initialzied with an
-        'empty' frozen node. but this is wrongly described in chapter
-        8.2.4 Initializing the Version History.
-
-        Version rootVersion = vHistory.getRootVersion();
-        try {
-            rootVersion.getNode(jcrFrozenNode);
-            fail("The root vesion must not store any state information.");
-        } catch (PathNotFoundException e) {
-            // success
-        }
-
-        */
-    }
-
-    /**
      * The version history must initially contain two versions (root version +
      * first test version).
      *

Modified: incubator/jackrabbit/trunk/core/src/test/org/apache/jackrabbit/test/api/version/VersionTest.java
URL: http://svn.apache.org/viewcvs/incubator/jackrabbit/trunk/core/src/test/org/apache/jackrabbit/test/api/version/VersionTest.java?rev=209050&r1=209049&r2=209050&view=diff
==============================================================================
--- incubator/jackrabbit/trunk/core/src/test/org/apache/jackrabbit/test/api/version/VersionTest.java
(original)
+++ incubator/jackrabbit/trunk/core/src/test/org/apache/jackrabbit/test/api/version/VersionTest.java
Mon Jul  4 02:45:45 2005
@@ -211,26 +211,6 @@
     }
 
     /**
-     * Tests if <code>Version.getDefinition()</code> returns the correct Node
-     * definition
-     * {@link Node#getDefinition()} is implementation specific, cannot be tested.
-     */
-    /*
-    public void testGetDefinition() throws Exception {
-        assertFalse("Version.getDefinition() does not return correct Node definition", version.getDefinition().allowsSameNameSiblings());
-        assertEquals("Version.getDefinition() does not return correct Node definition", ntVersionHistory,
version.getDefinition().getDeclaringNodeType().getName());
-        assertNull("Version.getDefinition() does not return correct Node definition", version.getDefinition().getDefaultPrimaryType());
-        assertEquals("Version.getDefinition() does not return correct Node definition", jcrFrozenNode,
version.getDefinition().getName());
-        assertEquals("Version.getDefinition() does not return correct Node definition", OnParentVersionAction.ABORT,
version.getDefinition().getOnParentVersion());
-        assertEquals("Version.getDefinition() does not return correct Node definition", jcrFrozenNode,
(version.getDefinition().getRequiredPrimaryTypes())[0].getName());
-        assertFalse("Version.getDefinition() does not return correct Node definition", version.getDefinition().isAutoCreated());
-        assertFalse("Version.getDefinition() does not return correct Node definition", version.getDefinition().isMandatory());
-        assertTrue("Version.getDefinition() does not return correct Node definition", version.getDefinition().isProtected());
-    }
-    */
-
-
-    /**
      * Tests if <code>Version.getDepth()</code> returns the right depth
      */
     public void testGetDepth() throws Exception {
@@ -352,35 +332,6 @@
      */
     public void testGetProperty() throws Exception {
         assertTrue("Version.getProperty(String) does not return property jcr:created", version.getProperty(jcrCreated).getName().equals(jcrCreated));
-    }
-
-    /**
-     * Tests if <code>Version.getReferences()</code> returns the right reference
-     * to the current node
-     */
-    public void testGetReferences() throws Exception {
-        /*
-
-        inter-versionstorage references MAY not be supported by the rep.
-
-        PropertyIterator pi = version.getReferences();
-        boolean hasRootVersionReference = false;
-        while (pi.hasNext()) {
-            Property p = pi.nextProperty();
-            if (p.getName().equals(jcrSuccessors) && p.getDefinition().isMultiple())
{
-                Value[] values = p.getValues();
-                for (int i = 0; i < values.length; i++) {
-                    Value value = values[i];
-                    if (superuser.getNodeByUUID(value.getString()).isNodeType(ntVersion))
{
-                        hasRootVersionReference = true;
-                        break;
-                    }
-                }
-            }
-        }
-        assertTrue("Version.getReferences() does not return the jcr:successors property of
the jcr:rootVersion", hasRootVersionReference);
-
-        */
     }
 
     /**



Mime
View raw message