jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mreut...@apache.org
Subject svn commit: r807176 - /jackrabbit/sandbox/jackrabbit-test-harness/compatibility/base/src/main/java/org/apache/jackrabbit/harness/compatibility/AbstractRepositoryTest.java
Date Mon, 24 Aug 2009 12:18:06 GMT
Author: mreutegg
Date: Mon Aug 24 12:18:06 2009
New Revision: 807176

URL: http://svn.apache.org/viewvc?rev=807176&view=rev
Log:
- open up test and verify methods
- provide hooks for user test

Modified:
    jackrabbit/sandbox/jackrabbit-test-harness/compatibility/base/src/main/java/org/apache/jackrabbit/harness/compatibility/AbstractRepositoryTest.java

Modified: jackrabbit/sandbox/jackrabbit-test-harness/compatibility/base/src/main/java/org/apache/jackrabbit/harness/compatibility/AbstractRepositoryTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/sandbox/jackrabbit-test-harness/compatibility/base/src/main/java/org/apache/jackrabbit/harness/compatibility/AbstractRepositoryTest.java?rev=807176&r1=807175&r2=807176&view=diff
==============================================================================
--- jackrabbit/sandbox/jackrabbit-test-harness/compatibility/base/src/main/java/org/apache/jackrabbit/harness/compatibility/AbstractRepositoryTest.java
(original)
+++ jackrabbit/sandbox/jackrabbit-test-harness/compatibility/base/src/main/java/org/apache/jackrabbit/harness/compatibility/AbstractRepositoryTest.java
Mon Aug 24 12:18:06 2009
@@ -146,16 +146,17 @@
         }
     }
 
-    private void createTestData(Session session) throws Exception {
+    protected void createTestData(Session session) throws Exception {
         Node root = session.getRootNode();
         Node test = root.addNode("test", "nt:unstructured");
         root.save();
 
         Node versionable = createVersionable(test);
         createProperties(test, versionable);
+        createUsers(session);
     }
 
-    private void verifyTestData(Session session) throws Exception {
+    protected void verifyTestData(Session session) throws Exception {
         Node root = session.getRootNode();
 
         assertTrue(root.hasNode("test"));
@@ -163,9 +164,10 @@
 
         Node versionable = verifyVersionable(test);
         verifyProperties(test, versionable);
+        verifyUsers(session);
     }
 
-    private Node createVersionable(Node parent) throws RepositoryException {
+    protected Node createVersionable(Node parent) throws RepositoryException {
         Node versionable = parent.addNode("versionable", "nt:unstructured");
         versionable.addMixin("mix:versionable");
         versionable.setProperty("foo", "A");
@@ -182,7 +184,7 @@
         return versionable;
     }
 
-    private Node verifyVersionable(Node test) throws RepositoryException {
+    protected Node verifyVersionable(Node test) throws RepositoryException {
         assertTrue(test.hasNode("versionable"));
         Node versionable = test.getNode("versionable");
         assertTrue(versionable.isNodeType("nt:unstructured"));
@@ -202,7 +204,7 @@
         return versionable;
     }
 
-    private void createProperties(Node parent, Node reference)
+    protected void createProperties(Node parent, Node reference)
             throws RepositoryException {
         Node properties = parent.addNode("properties", "nt:unstructured");
         properties.setProperty("boolean", true);
@@ -224,7 +226,7 @@
         parent.save();
     }
 
-    private void verifyProperties(Node test, Node versionable)
+    protected void verifyProperties(Node test, Node versionable)
             throws RepositoryException, PathNotFoundException,
             ValueFormatException, IOException {
         assertTrue(test.hasNode("properties"));
@@ -257,5 +259,10 @@
         }
     }
 
+    protected void createUsers(Session session) throws RepositoryException {
+    }
+
+    protected void verifyUsers(Session session) throws RepositoryException {
+    }
 }
 



Mime
View raw message