jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ju...@apache.org
Subject svn commit: r708635 - in /jackrabbit/branches/1.5: ./ jackrabbit-core/src/main/java/org/apache/jackrabbit/core/security/ jackrabbit-ocm-nodemanagement/src/main/java/org/apache/jackrabbit/ocm/nodemanagement/impl/jackrabbit/ jackrabbit-ocm-nodemanagement...
Date Tue, 28 Oct 2008 19:11:39 GMT
Author: jukka
Date: Tue Oct 28 12:11:38 2008
New Revision: 708635

URL: http://svn.apache.org/viewvc?rev=708635&view=rev
Log:
1.5: Merged revision 708634 (JCR-1840).

Added:
    jackrabbit/branches/1.5/jackrabbit-ocm-nodemanagement/src/test/resources/
      - copied from r708634, jackrabbit/trunk/jackrabbit-ocm-nodemanagement/src/test/resources/
    jackrabbit/branches/1.5/jackrabbit-ocm-nodemanagement/src/test/resources/log4j.properties
      - copied unchanged from r708634, jackrabbit/trunk/jackrabbit-ocm-nodemanagement/src/test/resources/log4j.properties
Removed:
    jackrabbit/branches/1.5/jackrabbit-ocm-nodemanagement/src/test/log4j.properties
Modified:
    jackrabbit/branches/1.5/   (props changed)
    jackrabbit/branches/1.5/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/security/AccessControlPolicyIteratorAdapter.java
  (props changed)
    jackrabbit/branches/1.5/jackrabbit-ocm-nodemanagement/src/main/java/org/apache/jackrabbit/ocm/nodemanagement/impl/jackrabbit/NodeTypeManagerImpl.java
    jackrabbit/branches/1.5/jackrabbit-ocm-nodemanagement/src/test/java/org/apache/jackrabbit/ocm/nodemanagement/impl/jackrabbit/NodeTypeManagerImplTest.java
    jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/AbstractTestBase.java
    jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/atomic/AnnotationAtomicTest.java
    jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/atomic/AnnotationDefaultValueTest.java
    jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/atomic/AnnotationNullAtomicTest.java
    jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/beanconverter/AnnotationBeanDescriptorTest.java
    jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/beanconverter/DigesterBeanDescriptorTest.java
    jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/jcrnodetype/AnnotationJcrNodeTypeTest.java
    jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/jcrnodetype/AnnotationJcrPropertyTest.java
    jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/jcrnodetype/DigesterJcrNodeTypeTest.java
    jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/jcrnodetype/DigesterJcrPropertyTest.java
    jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/query/AnnotationAtomicQueryTest.java
    jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/query/AnnotationIteratorQueryTest.java
    jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/query/DigesterAtomicQueryTest.java
    jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/query/DigesterIteratorQueryTest.java
    jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/uuid/AnnotationUuidTest.java
    jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/uuid/DigesterUuidTest.java
    jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/version/AnnotationBasicVersionningTest.java
    jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/version/DigesterBasicVersionningTest.java
    jackrabbit/branches/1.5/jackrabbit-ocm/src/test/resources/log4j.properties

Propchange: jackrabbit/branches/1.5/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Oct 28 12:11:38 2008
@@ -1,2 +1,2 @@
 /jackrabbit/branches/1.3:631261
-/jackrabbit/trunk:703899-704158,704165,704167,704324,704358,704361,704864,704933,704939,705010,705033,705243,705496,705522,705579,705925,705932,705934,705937-705938,705961,706242,706273,706285-706286,706562,706606,706649,706655,706660,706697,706918,707303-707304,707307,707310,707630,708206,708598,708609,708613,708619
+/jackrabbit/trunk:703899-704158,704165,704167,704324,704358,704361,704864,704933,704939,705010,705033,705243,705496,705522,705579,705925,705932,705934,705937-705938,705961,706242,706273,706285-706286,706562,706606,706649,706655,706660,706697,706918,707303-707304,707307,707310,707630,708206,708598,708609,708613,708619,708634

Propchange: jackrabbit/branches/1.5/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/security/AccessControlPolicyIteratorAdapter.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Oct 28 12:11:38 2008
@@ -1,2 +1,2 @@
 /jackrabbit/branches/1.3/jackrabbit-core/src/main/java/org/apache/jackrabbit/commons/iterator/AccessControlPolicyIteratorAdapter.java:631261
-/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/security/AccessControlPolicyIteratorAdapter.java:705938,705961,706242,706273
+/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/security/AccessControlPolicyIteratorAdapter.java:705938,705961,706242,706273,708634

Modified: jackrabbit/branches/1.5/jackrabbit-ocm-nodemanagement/src/main/java/org/apache/jackrabbit/ocm/nodemanagement/impl/jackrabbit/NodeTypeManagerImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm-nodemanagement/src/main/java/org/apache/jackrabbit/ocm/nodemanagement/impl/jackrabbit/NodeTypeManagerImpl.java?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm-nodemanagement/src/main/java/org/apache/jackrabbit/ocm/nodemanagement/impl/jackrabbit/NodeTypeManagerImpl.java
(original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm-nodemanagement/src/main/java/org/apache/jackrabbit/ocm/nodemanagement/impl/jackrabbit/NodeTypeManagerImpl.java
Tue Oct 28 12:11:38 2008
@@ -217,7 +217,6 @@
         }
         catch (Exception e)
         {
-            e.printStackTrace();
             log.error("Could not create node types from class descriptor.", e);
             throw new NodeTypeCreationException(e);
         }

Modified: jackrabbit/branches/1.5/jackrabbit-ocm-nodemanagement/src/test/java/org/apache/jackrabbit/ocm/nodemanagement/impl/jackrabbit/NodeTypeManagerImplTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm-nodemanagement/src/test/java/org/apache/jackrabbit/ocm/nodemanagement/impl/jackrabbit/NodeTypeManagerImplTest.java?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm-nodemanagement/src/test/java/org/apache/jackrabbit/ocm/nodemanagement/impl/jackrabbit/NodeTypeManagerImplTest.java
(original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm-nodemanagement/src/test/java/org/apache/jackrabbit/ocm/nodemanagement/impl/jackrabbit/NodeTypeManagerImplTest.java
Tue Oct 28 12:11:38 2008
@@ -33,6 +33,8 @@
 import org.apache.jackrabbit.ocm.nodemanagement.exception.NamespaceCreationException;
 import org.apache.jackrabbit.ocm.nodemanagement.exception.NodeTypeCreationException;
 import org.apache.jackrabbit.ocm.nodemanagement.impl.jackrabbit.NodeTypeManagerImpl;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 
 /** JUnit test for NodeTypeManagerImpl.
@@ -41,6 +43,12 @@
  */
 public class NodeTypeManagerImplTest extends TestBase {
 
+    /**
+     * Logger instance.
+     */
+    private static final Logger log =
+        LoggerFactory.getLogger(NodeTypeManagerImpl.class);
+
     /** Class to test.
      */
     private NodeTypeManagerImpl jackrabbitNodeTypeManagerImpl
@@ -136,11 +144,11 @@
         assertTrue(containsProperty("jcr:mixinTypes", testNodeType.getPropertyDefinitions()));
 
         PropertyDefinition propDef1 = getPropertyDefinition(testNodeType.getPropertyDefinitions(),
"ocm:a");
-        System.out.println(getJackrabbitNodeTypeManagerImpl().showPropertyDefinition(propDef1));
+        log.info(getJackrabbitNodeTypeManagerImpl().showPropertyDefinition(propDef1));
         // TODO test all properties
 
         PropertyDefinition propDef2 = getPropertyDefinition(testNodeType.getPropertyDefinitions(),
"ocm:b");
-        System.out.println(getJackrabbitNodeTypeManagerImpl().showPropertyDefinition(propDef2));
+        log.info(getJackrabbitNodeTypeManagerImpl().showPropertyDefinition(propDef2));
         // TODO test all properties
     }
 

Modified: jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/AbstractTestBase.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/AbstractTestBase.java?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/AbstractTestBase.java
(original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/AbstractTestBase.java
Tue Oct 28 12:11:38 2008
@@ -106,7 +106,7 @@
 		}
 		catch (Exception e )
 		{
-			e.printStackTrace();
+		    log.error("setUp failed", e);
 		}
 	}
 
@@ -138,7 +138,7 @@
 		}
 		catch (Exception e)
 		{
-			e.printStackTrace();
+			log.error("getObjectContentManager failed", e);
 			return null;
 		}
 	}
@@ -184,8 +184,7 @@
 		}
 		catch (Exception e)
 		{
-			System.out.println("Impossible to export the content from : " + nodePath);
-			e.printStackTrace();
+			log.error("Impossible to export the content from : " + nodePath, e);
 		}
 	}
 
@@ -200,8 +199,7 @@
 		}
 		catch (Exception e)
 		{
-			System.out.println("Impossible to import the content from : " + nodePath);
-			e.printStackTrace();
+			log.error("Impossible to import the content from : " + nodePath, e);
 		}
 
 	}
@@ -260,7 +258,7 @@
 		}
 		catch(Exception e)
 		{
-			e.printStackTrace();
+			log.error("cleanUpRepository failed", e);
 		}
 	}
 

Modified: jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/atomic/AnnotationAtomicTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/atomic/AnnotationAtomicTest.java?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/atomic/AnnotationAtomicTest.java
(original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/atomic/AnnotationAtomicTest.java
Tue Oct 28 12:11:38 2008
@@ -185,7 +185,7 @@
         }
         catch (Exception e)
         {
-            e.printStackTrace();
+            log.error("testAtomicFields failed", e);
             fail("Exception occurs during the unit test : " + e);
         }
 

Modified: jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/atomic/AnnotationDefaultValueTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/atomic/AnnotationDefaultValueTest.java?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/atomic/AnnotationDefaultValueTest.java
(original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/atomic/AnnotationDefaultValueTest.java
Tue Oct 28 12:11:38 2008
@@ -85,7 +85,7 @@
 	    }
 	    catch (Exception e)
 	    {
-	        e.printStackTrace();
+	        log.error("testDefaultValues failed", e);
 	        fail("Exception occurs during the unit test : " + e);
 	    }
 	
@@ -125,7 +125,7 @@
         }
         catch (Exception e)
         {
-            e.printStackTrace();
+            log.error("testDefaultValuesRead failed", e);
             fail("Exception occurs during the unit test : " + e);
         }
 

Modified: jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/atomic/AnnotationNullAtomicTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/atomic/AnnotationNullAtomicTest.java?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/atomic/AnnotationNullAtomicTest.java
(original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/atomic/AnnotationNullAtomicTest.java
Tue Oct 28 12:11:38 2008
@@ -111,7 +111,7 @@
         }
         catch (Exception e)
         {
-            e.printStackTrace();
+            log.error("testNullValueAtomicFields failed", e);
             fail("Exception occurs during the unit test : " + e);
         }
 

Modified: jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/beanconverter/AnnotationBeanDescriptorTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/beanconverter/AnnotationBeanDescriptorTest.java?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/beanconverter/AnnotationBeanDescriptorTest.java
(original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/beanconverter/AnnotationBeanDescriptorTest.java
Tue Oct 28 12:11:38 2008
@@ -262,7 +262,7 @@
             page = (Page) ocm.getObject("/test");
             paragraphs = page.getParagraphs();
             for (Paragraph paragraph : paragraphs) {
-				System.out.println("Paragraph path : " + paragraph.getPath());				
+				log.info("Paragraph path : " + paragraph.getPath());				
 			}
             Paragraph p1 = (Paragraph) ocm.getObject("/test/paragraph[2]");
             Page paraPage = p1.getPage();

Modified: jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/beanconverter/DigesterBeanDescriptorTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/beanconverter/DigesterBeanDescriptorTest.java?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/beanconverter/DigesterBeanDescriptorTest.java
(original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/beanconverter/DigesterBeanDescriptorTest.java
Tue Oct 28 12:11:38 2008
@@ -263,7 +263,7 @@
             page = (Page) ocm.getObject("/test");
             paragraphs = page.getParagraphs();
             for (Paragraph paragraph : paragraphs) {
-				System.out.println("Paragraph path : " + paragraph.getPath());				
+				log.info("Paragraph path : " + paragraph.getPath());				
 			}
             Paragraph p1 = (Paragraph) ocm.getObject("/test/paragraph[2]");
             Page paraPage = p1.getPage();

Modified: jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/jcrnodetype/AnnotationJcrNodeTypeTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/jcrnodetype/AnnotationJcrNodeTypeTest.java?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/jcrnodetype/AnnotationJcrNodeTypeTest.java
(original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/jcrnodetype/AnnotationJcrNodeTypeTest.java
Tue Oct 28 12:11:38 2008
@@ -85,17 +85,17 @@
 			//---------------------------------------------------------------------------------------------------------
					
 			folder = (Folder) ocm.getObject( "/folder1");
 			assertNotNull("folder is null", folder);
-			System.out.println("Folder creation date : " + folder.getCreationDate());
+			log.info("Folder creation date : " + folder.getCreationDate());
 			assertTrue("Invalid number of children", folder.getChildren().size() == 1);
 			file = (File) folder.getChildren().iterator().next();
 			assertNotNull("resource is null", file.getResource());	
-			System.out.println("File resource calendar: " + file.getResource().getLastModified());
// The prop is autocreated
+			log.info("File resource calendar: " + file.getResource().getLastModified());	// The prop
is autocreated
 			
 			
 		}
 		catch (Exception e)
 		{
-			e.printStackTrace();
+			log.error("testRetrieveSingleton failed", e);
 			fail();
 		}
 			

Modified: jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/jcrnodetype/AnnotationJcrPropertyTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/jcrnodetype/AnnotationJcrPropertyTest.java?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/jcrnodetype/AnnotationJcrPropertyTest.java
(original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/jcrnodetype/AnnotationJcrPropertyTest.java
Tue Oct 28 12:11:38 2008
@@ -138,15 +138,15 @@
             	fail("Invalid value was accepted for mandatoryWithConstaintsProp");
             }
             catch(Exception e)
-            {                	
-                e.printStackTrace();
+            {
+                // expected
             }
 			
 			
 		}
 		catch (Exception e)
-		{			
-			e.printStackTrace();
+		{
+			log.error("testRequiredProperty failed", e);
 			fail();
 		}
 			

Modified: jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/jcrnodetype/DigesterJcrNodeTypeTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/jcrnodetype/DigesterJcrNodeTypeTest.java?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/jcrnodetype/DigesterJcrNodeTypeTest.java
(original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/jcrnodetype/DigesterJcrNodeTypeTest.java
Tue Oct 28 12:11:38 2008
@@ -87,17 +87,17 @@
 			//---------------------------------------------------------------------------------------------------------
					
 			folder = (Folder) ocm.getObject( "/folder1");
 			assertNotNull("folder is null", folder);
-			System.out.println("Folder creation date : " + folder.getCreationDate());
+			log.info("Folder creation date : " + folder.getCreationDate());
 			assertTrue("Invalid number of children", folder.getChildren().size() == 1);
 			file = (File) folder.getChildren().iterator().next();
 			assertNotNull("resource is null", file.getResource());	
-			System.out.println("File resource calendar: " + file.getResource().getLastModified());
// The prop is autocreated
+			log.info("File resource calendar: " + file.getResource().getLastModified());	// The prop
is autocreated
 			
 			
 		}
 		catch (Exception e)
 		{
-			e.printStackTrace();
+			log.error("testRetrieveSingleton failed", e);
 			fail();
 		}
 			

Modified: jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/jcrnodetype/DigesterJcrPropertyTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/jcrnodetype/DigesterJcrPropertyTest.java?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/jcrnodetype/DigesterJcrPropertyTest.java
(original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/jcrnodetype/DigesterJcrPropertyTest.java
Tue Oct 28 12:11:38 2008
@@ -137,15 +137,15 @@
             	fail("Invalid value was accepted for mandatoryWithConstaintsProp");
             }
             catch(Exception e)
-            {                	
-                e.printStackTrace();
+            {
+                // expected;
             }
 			
 			
 		}
 		catch (Exception e)
 		{			
-			e.printStackTrace();
+			log.error("testRequiredProperty failed", e);
 			fail();
 		}
 			

Modified: jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/query/AnnotationAtomicQueryTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/query/AnnotationAtomicQueryTest.java?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/query/AnnotationAtomicQueryTest.java
(original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/query/AnnotationAtomicQueryTest.java
Tue Oct 28 12:11:38 2008
@@ -83,7 +83,7 @@
 
 			long start = System.currentTimeMillis();
 			Collection result = ocm.getObjects(query);
-			System.out.println("getObjects  : " + (System.currentTimeMillis() - start));
+			log.info("getObjects  : " + (System.currentTimeMillis() - start));
 
 			assertTrue("Invalid number of objects - should be = 50", result.size() == 50);
 
@@ -93,7 +93,7 @@
 
 			start = System.currentTimeMillis();
 			result = ocm.getObjects(query);
-			System.out.println("getObjects 2 : " + (System.currentTimeMillis() - start));
+			log.info("getObjects 2 : " + (System.currentTimeMillis() - start));
 			assertTrue("Invalid number of objects - should be = 0", result.size() == 0);
 
 
@@ -198,7 +198,7 @@
 
 		long start = System.currentTimeMillis();
 		Collection result = ocm.getObjects(query);
-		System.out.println("getObjects  : " + (System.currentTimeMillis() - start));
+		log.info("getObjects  : " + (System.currentTimeMillis() - start));
 
 		assertEquals(50, result.size());
 	}

Modified: jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/query/AnnotationIteratorQueryTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/query/AnnotationIteratorQueryTest.java?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/query/AnnotationIteratorQueryTest.java
(original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/query/AnnotationIteratorQueryTest.java
Tue Oct 28 12:11:38 2008
@@ -97,16 +97,16 @@
     	
     	      long  start = System.currentTimeMillis();
               ObjectIterator iterator = (ObjectIterator) ocm.getObjectIterator(query);
-              System.out.println("getObjectIterator takes : " + (System.currentTimeMillis()
- start));
+              log.info("getObjectIterator takes : " + (System.currentTimeMillis() - start));
 
     	      start = System.currentTimeMillis();
     	      Collection result = ocm.getObjects(query);
-    	      System.out.println("getObject takes : " + (System.currentTimeMillis() - start));
+    	      log.info("getObject takes : " + (System.currentTimeMillis() - start));
     	
 
     	      start = System.currentTimeMillis();
     	      iterator = (ObjectIterator) ocm.getObjectIterator(query);
-              System.out.println("getObjectIterator takes : " + (System.currentTimeMillis()
- start));
+              log.info("getObjectIterator takes : " + (System.currentTimeMillis() - start));
               assertEquals("wrong results count", 4, iterator.getSize());
               assertEquals("wrong initial position", 0, iterator.getPosition());
               assertTrue("no objects returned", iterator.hasNext());

Modified: jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/query/DigesterAtomicQueryTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/query/DigesterAtomicQueryTest.java?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/query/DigesterAtomicQueryTest.java
(original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/query/DigesterAtomicQueryTest.java
Tue Oct 28 12:11:38 2008
@@ -83,7 +83,7 @@
 
 			long start = System.currentTimeMillis();
 			Collection result = ocm.getObjects(query);
-			System.out.println("getObjects  : " + (System.currentTimeMillis() - start));
+			log.info("getObjects  : " + (System.currentTimeMillis() - start));
 
 			assertTrue("Invalid number of objects - should be = 50", result.size() == 50);
 
@@ -93,7 +93,7 @@
 
 			start = System.currentTimeMillis();
 			result = ocm.getObjects(query);
-			System.out.println("getObjects 2 : " + (System.currentTimeMillis() - start));
+			log.info("getObjects 2 : " + (System.currentTimeMillis() - start));
 			assertTrue("Invalid number of objects - should be = 0", result.size() == 0);
 
 
@@ -198,7 +198,7 @@
 
 		long start = System.currentTimeMillis();
 		Collection result = ocm.getObjects(query);
-		System.out.println("getObjects  : " + (System.currentTimeMillis() - start));
+		log.info("getObjects  : " + (System.currentTimeMillis() - start));
 
 		assertEquals(50, result.size());
 	}

Modified: jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/query/DigesterIteratorQueryTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/query/DigesterIteratorQueryTest.java?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/query/DigesterIteratorQueryTest.java
(original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/query/DigesterIteratorQueryTest.java
Tue Oct 28 12:11:38 2008
@@ -95,15 +95,15 @@
     	
     	      long  start = System.currentTimeMillis();
     	      Iterator iterator = ocm.getObjectIterator(query);
-    	      System.out.println("getObject takes : " + (System.currentTimeMillis() - start));
+    	      log.info("getObject takes : " + (System.currentTimeMillis() - start));
     	          	
     	      start = System.currentTimeMillis();
     	      Collection result = ocm.getObjects(query);
-    	      System.out.println("getObject takes : " + (System.currentTimeMillis() - start));
+    	      log.info("getObject takes : " + (System.currentTimeMillis() - start));
     	
     	      start = System.currentTimeMillis();
     	      iterator = ocm.getObjectIterator(query);
-    	      System.out.println("getObject takes : " + (System.currentTimeMillis() - start));
      	
+    	      log.info("getObject takes : " + (System.currentTimeMillis() - start));       

 
     	
         }

Modified: jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/uuid/AnnotationUuidTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/uuid/AnnotationUuidTest.java?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/uuid/AnnotationUuidTest.java
(original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/uuid/AnnotationUuidTest.java
Tue Oct 28 12:11:38 2008
@@ -140,7 +140,7 @@
             assertNotNull("a is null", a);
             uuidA = a.getUuid();
             assertNotNull("uuid is null", uuidA);
-            System.out.println("UUID : " + uuidA);
+            log.info("UUID : " + uuidA);
 
             // --------------------------------------------------------------------------------
             // Update the object
@@ -174,7 +174,7 @@
             catch(Exception e)
             {
             	//Throws an exception due to an invalid uuid
-            	System.out.println(e);
+            	log.info(e);
 
             }
 
@@ -215,7 +215,7 @@
             assertNotNull("a is null", a);
             String uuidA = a.getUuid();
             assertNotNull("uuid is null", uuidA);
-            System.out.println("UUID : " + uuidA);
+            log.info("UUID : " + uuidA);
 
             // --------------------------------------------------------------------------------
             // Create and store an object B in the repository which has a reference to A
@@ -245,7 +245,7 @@
             catch(Exception e)
             {
             	//Throws an exception due to an invalid uuid
-            	System.out.println("Invalid uuid : " + e);
+            	log.info("Invalid uuid : " + e);
 
             }
 
@@ -288,7 +288,7 @@
             assertNotNull("a is null", a);
             String uuidA = a.getUuid();
             assertNotNull("uuid is null", uuidA);
-            System.out.println("UUID : " + uuidA);
+            log.info("UUID : " + uuidA);
 
             // --------------------------------------------------------------------------------
             // Create and store an object B in the repository which has a reference to A
@@ -398,7 +398,7 @@
             catch(Exception e)
             {
             	//Throws an exception due to an invalid uuid
-            	System.out.println("Invalid uuid value in the collection : " + e);
+            	log.info("Invalid uuid value in the collection : " + e);
 
             }
 
@@ -531,7 +531,7 @@
             assertNotNull("a is null", a);
             String uuidA = a.getUuid();
             assertNotNull("uuid is null", uuidA);
-            System.out.println("UUID : " + uuidA);
+            log.info("UUID : " + uuidA);
 
             // --------------------------------------------------------------------------------
             // Update the object

Modified: jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/uuid/DigesterUuidTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/uuid/DigesterUuidTest.java?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/uuid/DigesterUuidTest.java
(original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/uuid/DigesterUuidTest.java
Tue Oct 28 12:11:38 2008
@@ -89,7 +89,7 @@
             assertNotNull("a is null", a);
             uuidA = a.getUuid();
             assertNotNull("uuid is null", uuidA);
-            System.out.println("UUID : " + uuidA);
+            log.info("UUID : " + uuidA);
 
             // --------------------------------------------------------------------------------
             // Update the object
@@ -123,7 +123,7 @@
             catch(Exception e)
             {
             	//Throws an exception due to an invalid uuid
-            	System.out.println(e);
+            	log.info(e);
 
             }
 
@@ -164,7 +164,7 @@
             assertNotNull("a is null", a);
             String uuidA = a.getUuid();
             assertNotNull("uuid is null", uuidA);
-            System.out.println("UUID : " + uuidA);
+            log.info("UUID : " + uuidA);
 
             // --------------------------------------------------------------------------------
             // Create and store an object B in the repository which has a reference to A
@@ -194,7 +194,7 @@
             catch(Exception e)
             {
             	//Throws an exception due to an invalid uuid
-            	System.out.println("Invalid uuid : " + e);
+            	log.info("Invalid uuid : " + e);
             	
             }
 
@@ -237,7 +237,7 @@
             assertNotNull("a is null", a);
             String uuidA = a.getUuid();
             assertNotNull("uuid is null", uuidA);
-            System.out.println("UUID : " + uuidA);
+            log.info("UUID : " + uuidA);
 
             // --------------------------------------------------------------------------------
             // Create and store an object B in the repository which has a reference to A
@@ -347,7 +347,7 @@
             catch(Exception e)
             {
             	//Throws an exception due to an invalid uuid
-            	System.out.println("Invalid uuid value in the collection : " + e);
+            	log.info("Invalid uuid value in the collection : " + e);
             	
             }
 
@@ -480,7 +480,7 @@
             assertNotNull("a is null", a);
             String uuidA = a.getUuid();
             assertNotNull("uuid is null", uuidA);
-            System.out.println("UUID : " + uuidA);
+            log.info("UUID : " + uuidA);
 
             // --------------------------------------------------------------------------------
             // Update the object

Modified: jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/version/AnnotationBasicVersionningTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/version/AnnotationBasicVersionningTest.java?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/version/AnnotationBasicVersionningTest.java
(original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/version/AnnotationBasicVersionningTest.java
Tue Oct 28 12:11:38 2008
@@ -120,10 +120,10 @@
             	 }
 
             	 Version baseVersion = ocm.getBaseVersion("/page");
-            	 System.out.println("Base version : " + baseVersion.getName());
+            	 log.info("Base version : " + baseVersion.getName());
 
             	 Version rootVersion = ocm.getRootVersion("/page");
-            	 System.out.println("Root version : " + rootVersion.getName());
+            	 log.info("Root version : " + rootVersion.getName());
             	 //this.exportDocument("/home/christophe/export.xml", "/jcr:system/jcr:versionStorage",
true, false);
 
                  //Get the latest version
@@ -245,10 +245,10 @@
             	 }
 
             	 Version baseVersion = ocm.getBaseVersion("/page");
-            	 System.out.println("Base version : " + baseVersion.getName());
+            	 log.info("Base version : " + baseVersion.getName());
 
             	 Version rootVersion = ocm.getRootVersion("/page");
-            	 System.out.println("Root version : " + rootVersion.getName());
+            	 log.info("Root version : " + rootVersion.getName());
             	 //this.exportDocument("/home/christophe/export.xml", "/jcr:system/jcr:versionStorage",
true, false);
 
                  //Get the latest version

Modified: jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/version/DigesterBasicVersionningTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/version/DigesterBasicVersionningTest.java?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/version/DigesterBasicVersionningTest.java
(original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm/src/test/java/org/apache/jackrabbit/ocm/manager/version/DigesterBasicVersionningTest.java
Tue Oct 28 12:11:38 2008
@@ -116,10 +116,10 @@
         	 }
         	
         	 Version baseVersion = ocm.getBaseVersion("/page");
-        	 System.out.println("Base version : " + baseVersion.getName());
+        	 log.info("Base version : " + baseVersion.getName());
 
         	 Version rootVersion = ocm.getRootVersion("/page");
-        	 System.out.println("Root version : " + rootVersion.getName());
+        	 log.info("Root version : " + rootVersion.getName());
         	             	
              //Get the latest version
         	 page = (Page) ocm.getObject( "/page");

Modified: jackrabbit/branches/1.5/jackrabbit-ocm/src/test/resources/log4j.properties
URL: http://svn.apache.org/viewvc/jackrabbit/branches/1.5/jackrabbit-ocm/src/test/resources/log4j.properties?rev=708635&r1=708634&r2=708635&view=diff
==============================================================================
--- jackrabbit/branches/1.5/jackrabbit-ocm/src/test/resources/log4j.properties (original)
+++ jackrabbit/branches/1.5/jackrabbit-ocm/src/test/resources/log4j.properties Tue Oct 28
12:11:38 2008
@@ -1,38 +1,24 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-# ------------------------------------------------------------------------
-#
-# Logging Configuration
+#  Licensed to the Apache Software Foundation (ASF) under one or more
+#  contributor license agreements.  See the NOTICE file distributed with
+#  this work for additional information regarding copyright ownership.
+#  The ASF licenses this file to You under the Apache License, Version 2.0
+#  (the "License"); you may not use this file except in compliance with
+#  the License.  You may obtain a copy of the License at
 #
-# $Id: Log4j.properties,v 1.3 2004/12/22 20:37:04 christophe Exp $
+#      http://www.apache.org/licenses/LICENSE-2.0
 #
-# ------------------------------------------------------------------------
-
-log4j.rootLogger = ERROR, console
+#  Unless required by applicable law or agreed to in writing, software
+#  distributed under the License is distributed on an "AS IS" BASIS,
+#  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+#  See the License for the specific language governing permissions and
+#  limitations under the License.
 
-log4j.category.org.apache.jackrabbit.ocm= WARN, console
-log4j.additivity.org.apache.jackrabbit.ocm=false
+log4j.rootLogger=INFO, file
 
-#
-# Console
-#
-log4j.appender.console=org.apache.log4j.ConsoleAppender
-log4j.appender.console.layout=org.apache.log4j.PatternLayout
+# 'file' is set to be a FileAppender.
+log4j.appender.file=org.apache.log4j.FileAppender
+log4j.appender.file.File=target/test-output.log
 
-# Pattern to output the caller's file name and line number.
-log4j.appender.console.layout.ConversionPattern=%5p: %m%n
\ No newline at end of file
+# 'file' uses PatternLayout.
+log4j.appender.file.layout=org.apache.log4j.PatternLayout
+log4j.appender.file.layout.ConversionPattern=%d{dd.MM.yyyy HH:mm:ss} *%-5p* [%t] %c{1}: %m
(%F, line %L)\n



Mime
View raw message