test/java/util/TimeZone/TimeZoneDatePermissionCheck.sh
Print this page
*** 28,54 ****
TESTCLASSES="."
fi
if [ "${TESTJAVA}" = "" ] ; then
TESTJAVA=/usr
fi
! # create a test keystore and dummy cert
rm -f ${TESTCLASSES}/timezonedatetest.store
! ${TESTJAVA}/bin/keytool -genkeypair -alias testcert \
-keystore ${TESTCLASSES}/timezonedatetest.store \
-storepass testpass -validity 360 \
-dname "cn=Mark Wildebeest, ou=FreeSoft, o=Red Hat, c=NL" \
-keypass testpass
# create a jar file to sign with the test class in it.
rm -f ${TESTCLASSES}/timezonedatetest.jar
! ${TESTJAVA}/bin/jar cf \
${TESTCLASSES}/timezonedatetest.jar \
-C ${TESTCLASSES} TimeZoneDatePermissionCheck.class
# sign it
! ${TESTJAVA}/bin/jarsigner \
-keystore ${TESTCLASSES}/timezonedatetest.store \
-storepass testpass ${TESTCLASSES}/timezonedatetest.jar testcert
# run it with the security manager on, plus accesscontroller debugging
# will go into infinite recursion trying to get enough permissions for
--- 28,58 ----
TESTCLASSES="."
fi
if [ "${TESTJAVA}" = "" ] ; then
TESTJAVA=/usr
fi
+ if [ "${COMPILEJAVA}" = "" ]; then
+ COMPILEJAVA="${TESTJAVA}"
+ fi
! # create a test keystore and dummy cert. Note that we use the COMPILEJAVA
! # as this test is a TimeZone test, it doesn't test keytool
rm -f ${TESTCLASSES}/timezonedatetest.store
! ${COMPILEJAVA}/bin/keytool ${TESTTOOLVMOPTS} -genkeypair -alias testcert \
-keystore ${TESTCLASSES}/timezonedatetest.store \
-storepass testpass -validity 360 \
-dname "cn=Mark Wildebeest, ou=FreeSoft, o=Red Hat, c=NL" \
-keypass testpass
# create a jar file to sign with the test class in it.
rm -f ${TESTCLASSES}/timezonedatetest.jar
! ${COMPILEJAVA}/bin/jar ${TESTTOOLVMOPTS} cf \
${TESTCLASSES}/timezonedatetest.jar \
-C ${TESTCLASSES} TimeZoneDatePermissionCheck.class
# sign it
! ${COMPILEJAVA}/bin/jarsigner ${TESTTOOLVMOPTS} \
-keystore ${TESTCLASSES}/timezonedatetest.store \
-storepass testpass ${TESTCLASSES}/timezonedatetest.jar testcert
# run it with the security manager on, plus accesscontroller debugging
# will go into infinite recursion trying to get enough permissions for