cayenne-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aadamc...@apache.org
Subject svn commit: r1101568 - /cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/test/java/org/apache/cayenne/access/trans/QueryAssemblerTest.java
Date Tue, 10 May 2011 18:00:18 GMT
Author: aadamchik
Date: Tue May 10 18:00:18 2011
New Revision: 1101568

URL: http://svn.apache.org/viewvc?rev=1101568&view=rev
Log:
CAY-1563 CayenneCase unit tests conversion(3)

patch by Dzmitry Kazimirchyk - QueryAssemblerTest + direct injection of DataNode

Modified:
    cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/test/java/org/apache/cayenne/access/trans/QueryAssemblerTest.java

Modified: cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/test/java/org/apache/cayenne/access/trans/QueryAssemblerTest.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/test/java/org/apache/cayenne/access/trans/QueryAssemblerTest.java?rev=1101568&r1=1101567&r2=1101568&view=diff
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/test/java/org/apache/cayenne/access/trans/QueryAssemblerTest.java
(original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/test/java/org/apache/cayenne/access/trans/QueryAssemblerTest.java
Tue May 10 18:00:18 2011
@@ -19,17 +19,24 @@
 
 package org.apache.cayenne.access.trans;
 
+import org.apache.cayenne.access.DataNode;
+import org.apache.cayenne.di.Inject;
 import org.apache.cayenne.map.DbAttribute;
 import org.apache.cayenne.query.SelectQuery;
-import org.apache.cayenne.unit.CayenneCase;
+import org.apache.cayenne.unit.di.server.ServerCase;
+import org.apache.cayenne.unit.di.server.UseServerRuntime;
 
-public class QueryAssemblerTest extends CayenneCase {
+@UseServerRuntime(ServerCase.TESTMAP_PROJECT)
+public class QueryAssemblerTest extends ServerCase {
+
+    @Inject
+    private DataNode dataNode;
 
     protected TstQueryAssembler qa;
 
     @Override
-    protected void setUp() throws Exception {
-        qa = new TstQueryAssembler(getNode(), new SelectQuery());
+    protected void setUpAfterInjection() throws Exception {
+        qa = new TstQueryAssembler(dataNode, new SelectQuery());
     }
 
     public void testGetQuery() throws Exception {



Mime
View raw message