cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r907207 [2/2] - in /cxf/trunk: ./ api/ common/common/ common/common/src/main/java/org/apache/cxf/helpers/ common/common/src/main/java/org/apache/cxf/staxutils/ integration/jbi/ maven-plugins/codegen-plugin/ maven-plugins/corba/ parent/ rt/b...
Date Sat, 06 Feb 2010 12:50:26 GMT
Modified: cxf/trunk/tools/validator/src/test/java/org/apache/cxf/tools/validator/internal/WSDLRefValidatorTest.java
URL: http://svn.apache.org/viewvc/cxf/trunk/tools/validator/src/test/java/org/apache/cxf/tools/validator/internal/WSDLRefValidatorTest.java?rev=907207&r1=907206&r2=907207&view=diff
==============================================================================
--- cxf/trunk/tools/validator/src/test/java/org/apache/cxf/tools/validator/internal/WSDLRefValidatorTest.java
(original)
+++ cxf/trunk/tools/validator/src/test/java/org/apache/cxf/tools/validator/internal/WSDLRefValidatorTest.java
Sat Feb  6 12:50:23 2010
@@ -26,7 +26,6 @@
 import org.apache.cxf.Bus;
 import org.apache.cxf.BusFactory;
 import org.apache.cxf.common.i18n.Message;
-import org.apache.cxf.staxutils.StaxUtils;
 import org.apache.cxf.tools.validator.internal.model.XNode;
 import org.apache.cxf.wsdl11.WSDLDefinitionBuilder;
 import org.junit.Assert;
@@ -58,24 +57,29 @@
         assertEquals(2, results.getErrors().size());
         String t = results.getErrors().pop();
         String text = "{http://apache.org/hello_world/messages}[portType:GreeterA][operation:sayHi]";
-        Message msg;
-        if (StaxUtils.isWoodstox()) {
-            msg = new Message("FAILED_AT_POINT",
-                              WSDLRefValidator.LOG,
-                              27,
-                              2,
-                              new java.net.URI(wsdl).toURL(),
-                              text);
-        } else {
-            // sjsxp
-            msg = new Message("FAILED_AT_POINT",
-                              WSDLRefValidator.LOG,
-                              -1,
-                              -1,
-                              new java.net.URI(wsdl).toURL(),
-                              text);
-        }
-        assertEquals(msg.toString(), t);
+        Set<String> possibles = new HashSet<String>();
+        //woodstox
+        possibles.add(new Message("FAILED_AT_POINT",
+                    WSDLRefValidator.LOG,
+                    27,
+                    2,
+                    new java.net.URI(wsdl).toURL(),
+                    text).toString());
+        //Sun java6 stax parser
+        possibles.add(new Message("FAILED_AT_POINT",
+                                  WSDLRefValidator.LOG,
+                                  27,
+                                  31,
+                                  new java.net.URI(wsdl).toURL(),
+                                  text).toString());
+        //sjsxp
+        possibles.add(new Message("FAILED_AT_POINT",
+                                  WSDLRefValidator.LOG,
+                                  -1,
+                                  -1,
+                                  new java.net.URI(wsdl).toURL(),
+                                  text).toString());
+        assertTrue(possibles.contains(t));
     }
     
 
@@ -139,23 +143,29 @@
         
         assertEquals(1, results.getErrors().size());
         String text = "{http://schemas.apache.org/yoko/idl/OptionsPT}[message:getEmployee]";
-        Message msg;
-        if (StaxUtils.isWoodstox()) {
-            msg = new Message("FAILED_AT_POINT",
-                              WSDLRefValidator.LOG,
-                              42,
-                              6,
-                              new java.net.URI(wsdl).toURL(),
-                              text);
-        } else {
-            msg = new Message("FAILED_AT_POINT",
-                              WSDLRefValidator.LOG,
-                              -1,
-                              -1,
-                              new java.net.URI(wsdl).toURL(),
-                              text);
-        }
-        assertEquals(msg.toString(), results.getErrors().pop());
+        Set<String> possibles = new HashSet<String>();
+        //woodstox
+        possibles.add(new Message("FAILED_AT_POINT",
+                    WSDLRefValidator.LOG,
+                    42,
+                    6,
+                    new java.net.URI(wsdl).toURL(),
+                    text).toString());
+        //Sun java6 stax parser
+        possibles.add(new Message("FAILED_AT_POINT",
+                                  WSDLRefValidator.LOG,
+                                  42,
+                                  70,
+                                  new java.net.URI(wsdl).toURL(),
+                                  text).toString());
+        //sjsxp
+        possibles.add(new Message("FAILED_AT_POINT",
+                                  WSDLRefValidator.LOG,
+                                  -1,
+                                  -1,
+                                  new java.net.URI(wsdl).toURL(),
+                                  text).toString());
+        assertTrue(possibles.contains(results.getErrors().pop()));
     }
 
     @Test

Modified: cxf/trunk/tools/wsdlto/core/pom.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/tools/wsdlto/core/pom.xml?rev=907207&r1=907206&r2=907207&view=diff
==============================================================================
--- cxf/trunk/tools/wsdlto/core/pom.xml (original)
+++ cxf/trunk/tools/wsdlto/core/pom.xml Sat Feb  6 12:50:23 2010
@@ -89,19 +89,6 @@
             <artifactId>jaxb-impl</artifactId>
         </dependency>
         <dependency>
-            <groupId>org.apache.geronimo.specs</groupId>
-            <artifactId>geronimo-jaxws_2.1_spec</artifactId>
-        </dependency>
-        <dependency>
-            <groupId>javax.xml.soap</groupId>
-            <artifactId>saaj-api</artifactId>
-        </dependency>
-        <dependency>
-	    <groupId>${stax.impl.groupId}</groupId>
-	    <artifactId>${stax.impl.artifactId}</artifactId>
-            <scope>runtime</scope>
-        </dependency>
-        <dependency>
             <groupId>org.apache.cxf</groupId>
             <artifactId>cxf-common-utilities</artifactId>
             <version>${project.version}</version>
@@ -140,5 +127,27 @@
             </plugin>
         </plugins>
     </build>
-
+    <profiles>
+        <profile>
+            <id>jdk15</id>
+            <activation>
+                <jdk>1.5</jdk>
+            </activation>
+            <dependencies>
+                <dependency>
+                    <groupId>org.apache.geronimo.specs</groupId>
+                    <artifactId>geronimo-jaxws_2.1_spec</artifactId>
+                </dependency>
+                <dependency>
+                    <groupId>javax.xml.soap</groupId>
+                    <artifactId>saaj-api</artifactId>
+                </dependency>
+                <dependency>
+                    <groupId>${stax.impl.groupId}</groupId>
+                    <artifactId>${stax.impl.artifactId}</artifactId>
+                    <scope>runtime</scope>
+                </dependency>
+            </dependencies>
+        </profile>
+    </profiles>
 </project>

Modified: cxf/trunk/tools/wsdlto/misc/pom.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/tools/wsdlto/misc/pom.xml?rev=907207&r1=907206&r2=907207&view=diff
==============================================================================
--- cxf/trunk/tools/wsdlto/misc/pom.xml (original)
+++ cxf/trunk/tools/wsdlto/misc/pom.xml Sat Feb  6 12:50:23 2010
@@ -67,17 +67,6 @@
             <groupId>com.sun.xml.bind</groupId>
             <artifactId>jaxb-impl</artifactId>
         </dependency>
-
-        <dependency>
-            <groupId>javax.xml.soap</groupId>
-            <artifactId>saaj-api</artifactId>
-        </dependency>
-        <dependency>
-	    <groupId>${stax.impl.groupId}</groupId>
-	    <artifactId>${stax.impl.artifactId}</artifactId>
-            <scope>runtime</scope>
-        </dependency>
-
         <dependency>
             <groupId>org.apache.cxf</groupId>
             <artifactId>cxf-tools-common</artifactId>
@@ -117,5 +106,24 @@
         </dependency>
 
     </dependencies>
+    <profiles>
+        <profile>
+            <id>jdk15</id>
+            <activation>
+                <jdk>1.5</jdk>
+            </activation>
+            <dependencies>
+                <dependency>
+                    <groupId>javax.xml.soap</groupId>
+                    <artifactId>saaj-api</artifactId>
+                </dependency>
+                <dependency>
+                    <groupId>${stax.impl.groupId}</groupId>
+                    <artifactId>${stax.impl.artifactId}</artifactId>
+                    <scope>runtime</scope>
+                </dependency>
+            </dependencies>
+        </profile>
+    </profiles>
 
 </project>



Mime
View raw message