cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r587270 - in /incubator/cxf/branches/2.0.x-fixes: ./ rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/ rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/fortest/ rt/databinding/aegis/src/test/java/org/apache/c...
Date Mon, 22 Oct 2007 21:31:43 GMT
Author: dkulp
Date: Mon Oct 22 14:31:42 2007
New Revision: 587270

URL: http://svn.apache.org/viewvc?rev=587270&view=rev
Log:
Merged revisions 587247 via svnmerge from 
https://svn.apache.org/repos/asf/incubator/cxf/trunk

........
  r587247 | dkulp | 2007-10-22 16:50:10 -0400 (Mon, 22 Oct 2007) | 2 lines
  
  Test case for CXF-1021
........

Added:
    incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/ns2/
      - copied from r587247, incubator/cxf/trunk/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/ns2/
    incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/ns2/ObjectWithAMapNs2.java
      - copied unchanged from r587247, incubator/cxf/trunk/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/ns2/ObjectWithAMapNs2.java
Modified:
    incubator/cxf/branches/2.0.x-fixes/   (props changed)
    incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/MapsTest.java
    incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/fortest/MapTest.java
    incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/fortest/MapTestImpl.java
    incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/fortest/ObjectWithAMap.java

Propchange: incubator/cxf/branches/2.0.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.

Modified: incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/MapsTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/MapsTest.java?rev=587270&r1=587269&r2=587270&view=diff
==============================================================================
--- incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/MapsTest.java
(original)
+++ incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/MapsTest.java
Mon Oct 22 14:31:42 2007
@@ -31,6 +31,8 @@
 import org.apache.cxf.aegis.AbstractAegisTest;
 import org.apache.cxf.aegis.type.map.fortest.MapTest;
 import org.apache.cxf.aegis.type.map.fortest.MapTestImpl;
+import org.apache.cxf.aegis.type.map.fortest.ObjectWithAMap;
+import org.apache.cxf.aegis.type.map.ns2.ObjectWithAMapNs2;
 import org.apache.cxf.endpoint.Server;
 import org.apache.cxf.jaxws.JaxWsProxyFactoryBean;
 import org.apache.cxf.jaxws.JaxWsServerFactoryBean;
@@ -43,8 +45,8 @@
  */
 public class MapsTest extends AbstractAegisTest {
     
-    private MapTest clientInterface;
-    private Server server;
+    private static MapTest clientInterface;
+    private static Server server;
 
     @Before
     public void setUp() throws Exception {
@@ -87,5 +89,25 @@
     public void testInvocations() throws Exception {
         Map<Long, String> lts = clientInterface.getMapLongToString();
         assertEquals("twenty-seven", lts.get(Long.valueOf(27)));
+    }
+    
+    @Test
+    public void testObjectsWithMaps() throws Exception {
+        ObjectWithAMap obj1 = clientInterface.returnObjectWithAMap();
+        ObjectWithAMapNs2 obj2 = clientInterface.returnObjectWithAMapNs2();
+        assertNotNull(obj1);
+        assertNotNull(obj2);
+        
+        assertNotNull(obj1.getTheMap());
+        assertNotNull(obj2.getTheMap()); 
+        
+        assertEquals(2, obj1.getTheMap().size());
+        assertEquals(3, obj2.getTheMap().size());
+        
+        assertTrue(obj1.getTheMap().get("rainy"));
+        assertTrue(obj2.getTheMap().get("rainy"));
+        assertFalse(obj1.getTheMap().get("sunny"));
+        assertFalse(obj2.getTheMap().get("sunny"));
+        assertFalse(obj2.getTheMap().get("cloudy"));
     }
 }

Modified: incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/fortest/MapTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/fortest/MapTest.java?rev=587270&r1=587269&r2=587270&view=diff
==============================================================================
--- incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/fortest/MapTest.java
(original)
+++ incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/fortest/MapTest.java
Mon Oct 22 14:31:42 2007
@@ -23,6 +23,8 @@
 
 import javax.jws.WebService;
 
+import org.apache.cxf.aegis.type.map.ns2.ObjectWithAMapNs2;
+
 /**
  * 
  */
@@ -33,4 +35,8 @@
     void takeMap(ObjectWithAMap map);
     Map<String, Long> getMapStringToLong();
     Map<Long, String> getMapLongToString();
+    
+    ObjectWithAMapNs2 returnObjectWithAMapNs2();
+    void takeMapNs2(ObjectWithAMapNs2 map);
+    
 }

Modified: incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/fortest/MapTestImpl.java
URL: http://svn.apache.org/viewvc/incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/fortest/MapTestImpl.java?rev=587270&r1=587269&r2=587270&view=diff
==============================================================================
--- incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/fortest/MapTestImpl.java
(original)
+++ incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/fortest/MapTestImpl.java
Mon Oct 22 14:31:42 2007
@@ -22,6 +22,8 @@
 import java.util.HashMap;
 import java.util.Map;
 
+import org.apache.cxf.aegis.type.map.ns2.ObjectWithAMapNs2;
+
 public class MapTestImpl implements MapTest {
 
     public Map<String, Long> getMapStringToLong() {
@@ -35,7 +37,10 @@
     }
 
     public ObjectWithAMap returnObjectWithAMap() {
-        return new ObjectWithAMap();
+        ObjectWithAMap ret = new ObjectWithAMap();
+        ret.getTheMap().put("rainy", Boolean.TRUE);
+        ret.getTheMap().put("sunny", Boolean.FALSE);
+        return ret;
     }
 
     public Map<Long, String> getMapLongToString() {
@@ -43,6 +48,17 @@
         map.put(Long.valueOf(1), "one");
         map.put(Long.valueOf(27), "twenty-seven");
         return map;
+    }
+
+    public ObjectWithAMapNs2 returnObjectWithAMapNs2() {
+        ObjectWithAMapNs2 ret = new ObjectWithAMapNs2();
+        ret.getTheMap().put("rainy", Boolean.TRUE);
+        ret.getTheMap().put("sunny", Boolean.FALSE);
+        ret.getTheMap().put("cloudy", Boolean.FALSE);
+        return ret;
+    }
+
+    public void takeMapNs2(ObjectWithAMapNs2 map) {
     }
 
 }

Modified: incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/fortest/ObjectWithAMap.java
URL: http://svn.apache.org/viewvc/incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/fortest/ObjectWithAMap.java?rev=587270&r1=587269&r2=587270&view=diff
==============================================================================
--- incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/fortest/ObjectWithAMap.java
(original)
+++ incubator/cxf/branches/2.0.x-fixes/rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/map/fortest/ObjectWithAMap.java
Mon Oct 22 14:31:42 2007
@@ -30,8 +30,6 @@
     
     public ObjectWithAMap() {
         theMap = new HashMap<String, Boolean>();
-        theMap.put("rainy", Boolean.TRUE);
-        theMap.put("sunny", Boolean.FALSE);
     }
 
     public Map<String, Boolean> getTheMap() {



Mime
View raw message