cayenne-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From torehal...@apache.org
Subject svn commit: r612442 - /cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/test/java/org/apache/cayenne/merge/MergerFactoryTest.java
Date Wed, 16 Jan 2008 13:00:41 GMT
Author: torehalset
Date: Wed Jan 16 05:00:40 2008
New Revision: 612442

URL: http://svn.apache.org/viewvc?rev=612442&view=rev
Log:
clean up logging

Modified:
    cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/test/java/org/apache/cayenne/merge/MergerFactoryTest.java

Modified: cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/test/java/org/apache/cayenne/merge/MergerFactoryTest.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/test/java/org/apache/cayenne/merge/MergerFactoryTest.java?rev=612442&r1=612441&r2=612442&view=diff
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/test/java/org/apache/cayenne/merge/MergerFactoryTest.java
(original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/test/java/org/apache/cayenne/merge/MergerFactoryTest.java
Wed Jan 16 05:00:40 2008
@@ -39,6 +39,8 @@
 import org.apache.cayenne.map.ObjAttribute;
 import org.apache.cayenne.map.ObjEntity;
 import org.apache.cayenne.unit.CayenneCase;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
 
 public class MergerFactoryTest extends CayenneCase {
 
@@ -46,6 +48,8 @@
     private DataMap map;
 
     private List<String> tableNames = Arrays.asList("ARTIST", "PAINTING", "NEW_TABLE");
+    
+    private static final Log logObj = LogFactory.getLog(MergerFactoryTest.class);
 
     public DbMerger createMerger() {
         return new DbMerger() {
@@ -382,11 +386,7 @@
 
     private void logTokens(List<MergerToken> tokens) {
         for (MergerToken token : tokens) {
-            QueryLogger.log("token: " + token.toString());
-            if (token instanceof AbstractToDbToken) {
-                QueryLogger.log("  \\-->  "
-                        + ((AbstractToDbToken) token).createSql(node.getAdapter()));
-            }
+            logObj.info("token: " + token.toString());
         }
     }
 
@@ -440,7 +440,7 @@
         }
 
         for (DbEntity e : entitiesToRemove) {
-            QueryLogger.log("filter away " + e.getName());
+            logObj.info("filter away " + e.getName());
             map.removeDbEntity(e.getName(), true);
         }
 



Mime
View raw message