You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by co...@apache.org on 2013/03/25 11:18:29 UTC

svn commit: r1460586 - /cxf/branches/wss4j2.0-port/systests/rs-security/src/test/java/org/apache/cxf/systest/jaxrs/security/xml/JAXRSXmlSecTest.java

Author: coheigea
Date: Mon Mar 25 10:18:28 2013
New Revision: 1460586

URL: http://svn.apache.org/r1460586
Log:
Fixed a failing test with IBM JDK 7

Modified:
    cxf/branches/wss4j2.0-port/systests/rs-security/src/test/java/org/apache/cxf/systest/jaxrs/security/xml/JAXRSXmlSecTest.java

Modified: cxf/branches/wss4j2.0-port/systests/rs-security/src/test/java/org/apache/cxf/systest/jaxrs/security/xml/JAXRSXmlSecTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/wss4j2.0-port/systests/rs-security/src/test/java/org/apache/cxf/systest/jaxrs/security/xml/JAXRSXmlSecTest.java?rev=1460586&r1=1460585&r2=1460586&view=diff
==============================================================================
--- cxf/branches/wss4j2.0-port/systests/rs-security/src/test/java/org/apache/cxf/systest/jaxrs/security/xml/JAXRSXmlSecTest.java (original)
+++ cxf/branches/wss4j2.0-port/systests/rs-security/src/test/java/org/apache/cxf/systest/jaxrs/security/xml/JAXRSXmlSecTest.java Mon Mar 25 10:18:28 2013
@@ -161,6 +161,18 @@ public class JAXRSXmlSecTest extends Abs
     
     @Test
     public void testPostEncryptedBookGCM() throws Exception {
+        //
+        // This test fails with the IBM JDK 7
+        // IBM JDK 7 appears to require a GCMParameter class to be used, which
+        // only exists in JDK 7. The Sun JDK appears to be more lenient and 
+        // allows us to use the existing IVParameterSpec class.
+        //
+        if ("IBM Corporation".equals(System.getProperty("java.vendor"))
+            && System.getProperty("java.version") != null
+            &&  System.getProperty("java.version").startsWith("1.7")) {
+            return;
+        }
+        
         String address = "https://localhost:" + PORT + "/xmlenc/bookstore/books";
         Map<String, Object> properties = new HashMap<String, Object>();
         properties.put("ws-security.callback-handler",