7012365: TEST_BUG: test/java/nio/charset/spi/basic.sh can be run with Cygwin
authormchung
Mon, 08 Aug 2011 16:27:41 -0700
changeset 10149 3b6ad02f4a40
parent 10148 b951831be5f9
child 10150 dee4cb73adc3
7012365: TEST_BUG: test/java/nio/charset/spi/basic.sh can be run with Cygwin Reviewed-by: darcy
jdk/test/java/nio/charset/spi/basic.sh
--- a/jdk/test/java/nio/charset/spi/basic.sh	Mon Aug 08 16:26:25 2011 -0700
+++ b/jdk/test/java/nio/charset/spi/basic.sh	Mon Aug 08 16:27:41 2011 -0700
@@ -45,9 +45,19 @@
 JAVA=$TESTJAVA/bin/java
 JAR=$TESTJAVA/bin/jar
 
-JARD=`pwd`/x.jar
-EXTD=`pwd`/x.ext
-TESTD=`pwd`/x.test
+DIR=`pwd`
+case `uname` in
+  SunOS | Linux ) CPS=':' ;;
+  Windows* )      CPS=';' ;;
+  CYGWIN*  )
+    DIR=`/usr/bin/cygpath -a -s -m $DIR`
+    CPS=";";;
+  *)              echo "Unknown platform: `uname`"; exit 1 ;;
+esac
+
+JARD=$DIR/x.jar
+EXTD=$DIR/x.ext
+TESTD=$DIR/x.test
 
 CSS='US-ASCII 8859_1 iso-ir-6 UTF-16 windows-1252 !BAR cp1252'
 
@@ -84,12 +94,6 @@
 TMP=${TMP:-$TEMP}; TMP=${TMP:-/tmp}
 cd $TMP
 
-case `uname` in
-  SunOS | Linux ) CPS=':' ;;
-  Windows* )      CPS=';' ;;
-  *)              echo "Unknown platform: `uname`"; exit 1 ;;
-esac
-
 failures=0
 for where in ext app; do
   for security in none minimal-policy cp-policy; do