You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by dk...@apache.org on 2010/01/11 18:26:58 UTC
svn commit: r897958 - in /cxf/branches/2.2.x-fixes: ./
systests/ws-specs/src/test/java/org/apache/cxf/systest/ws/wssec11/
Author: dkulp
Date: Mon Jan 11 17:26:58 2010
New Revision: 897958
URL: http://svn.apache.org/viewvc?rev=897958&view=rev
Log:
Merged revisions 897950 via svnmerge from
https://svn.apache.org/repos/asf/cxf/trunk
........
r897950 | dkulp | 2010-01-11 12:10:11 -0500 (Mon, 11 Jan 2010) | 2 lines
[CXF-2613] Fix tests with IBM 1.6 JDK and restricted jars
Patch from Eamonn Dwyer applied
........
Modified:
cxf/branches/2.2.x-fixes/ (props changed)
cxf/branches/2.2.x-fixes/systests/ws-specs/src/test/java/org/apache/cxf/systest/ws/wssec11/WSSecurity111Test.java
cxf/branches/2.2.x-fixes/systests/ws-specs/src/test/java/org/apache/cxf/systest/ws/wssec11/WSSecurity112Test.java
cxf/branches/2.2.x-fixes/systests/ws-specs/src/test/java/org/apache/cxf/systest/ws/wssec11/WSSecurity11Common.java
Propchange: cxf/branches/2.2.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.
Modified: cxf/branches/2.2.x-fixes/systests/ws-specs/src/test/java/org/apache/cxf/systest/ws/wssec11/WSSecurity111Test.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.2.x-fixes/systests/ws-specs/src/test/java/org/apache/cxf/systest/ws/wssec11/WSSecurity111Test.java?rev=897958&r1=897957&r2=897958&view=diff
==============================================================================
--- cxf/branches/2.2.x-fixes/systests/ws-specs/src/test/java/org/apache/cxf/systest/ws/wssec11/WSSecurity111Test.java (original)
+++ cxf/branches/2.2.x-fixes/systests/ws-specs/src/test/java/org/apache/cxf/systest/ws/wssec11/WSSecurity111Test.java Mon Jan 11 17:26:58 2010
@@ -46,6 +46,11 @@
launchServer(Server.class, true)
);
} else {
+ if (WSSecurity11Common.isIBMJDK16()) {
+ System.out.println("Not running as there is a problem with 1.6 jdk and restricted jars");
+ return;
+ }
+
assertTrue(
"Server failed to launch",
// run the server in the same process
@@ -57,6 +62,11 @@
@Test
public void testClientServer() {
+ if ((!unrestrictedPoliciesInstalled)
+ && (WSSecurity11Common.isIBMJDK16())) {
+ System.out.println("Not running as there is a problem with 1.6 jdk and restricted jars");
+ return;
+ }
String[] argv = new String[] {
"A",
"A-NoTimestamp",
Modified: cxf/branches/2.2.x-fixes/systests/ws-specs/src/test/java/org/apache/cxf/systest/ws/wssec11/WSSecurity112Test.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.2.x-fixes/systests/ws-specs/src/test/java/org/apache/cxf/systest/ws/wssec11/WSSecurity112Test.java?rev=897958&r1=897957&r2=897958&view=diff
==============================================================================
--- cxf/branches/2.2.x-fixes/systests/ws-specs/src/test/java/org/apache/cxf/systest/ws/wssec11/WSSecurity112Test.java (original)
+++ cxf/branches/2.2.x-fixes/systests/ws-specs/src/test/java/org/apache/cxf/systest/ws/wssec11/WSSecurity112Test.java Mon Jan 11 17:26:58 2010
@@ -47,6 +47,11 @@
launchServer(Server.class, true)
);
} else {
+ if (WSSecurity11Common.isIBMJDK16()) {
+ System.out.println("Not running as there is a problem with 1.6 jdk and restricted jars");
+ return;
+ }
+
assertTrue(
"Server failed to launch",
// run the server in the same process
@@ -58,6 +63,12 @@
@Test
public void testClientServer() {
+ if ((!unrestrictedPoliciesInstalled)
+ && (WSSecurity11Common.isIBMJDK16())) {
+ System.out.println("Not running as there is a problem with 1.6 jdk and restricted jars");
+ return;
+ }
+
String[] argv = null;
if (unrestrictedPoliciesInstalled) {
argv = new String[] {
Modified: cxf/branches/2.2.x-fixes/systests/ws-specs/src/test/java/org/apache/cxf/systest/ws/wssec11/WSSecurity11Common.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.2.x-fixes/systests/ws-specs/src/test/java/org/apache/cxf/systest/ws/wssec11/WSSecurity11Common.java?rev=897958&r1=897957&r2=897958&view=diff
==============================================================================
--- cxf/branches/2.2.x-fixes/systests/ws-specs/src/test/java/org/apache/cxf/systest/ws/wssec11/WSSecurity11Common.java (original)
+++ cxf/branches/2.2.x-fixes/systests/ws-specs/src/test/java/org/apache/cxf/systest/ws/wssec11/WSSecurity11Common.java Mon Jan 11 17:26:58 2010
@@ -106,4 +106,28 @@
return unrestrictedPoliciesInstalled;
}
+ public static boolean isIBMJDK16() {
+ String fullVersion = System.getProperty("java.fullversion");
+ if (fullVersion == null) {
+ //Maybe one of the non IBM JDKs dont set this property, but
+ //the IBM one definitely does
+ return false;
+ }
+ if (fullVersion.indexOf("IBM") == -1) {
+ return false;
+ }
+
+ String javaVersion = System.getProperty("java.version");
+ double javaVersionNum = 0.0;
+ if (javaVersion.length() > 3) {
+ javaVersionNum = new Double(javaVersion.substring(0, 3)).doubleValue();
+ } else {
+ javaVersionNum = new Double(javaVersion).doubleValue();
+ }
+ if (javaVersionNum < 1.6) {
+ return false;
+ }
+
+ return true;
+ }
}