< prev index next >

test/com/sun/management/UnixOperatingSystemMXBean/GetMaxFileDescriptorCount.sh

Print this page
rev 1541 : 8003890: corelibs test scripts should pass TESTVMOPTS
Reviewed-by: chegar, alanb
Contributed-by: Mark Sheppard <mark.sheppard@oracle.com>


  26 # @bug     4858522
  27 # @summary 
  28 # @author  Steve Bohne
  29 #
  30 # @run shell GetMaxFileDescriptorCount.sh
  31 #
  32 
  33 #Set appropriate jdk
  34 
  35 if [ ! -z "${TESTJAVA}" ] ; then
  36      jdk="$TESTJAVA"
  37 else
  38      echo "--Error: TESTJAVA must be defined as the pathname of a jdk to test."
  39      exit 1
  40 fi
  41 
  42 runOne()
  43 { 
  44    echo "runOne $@"
  45    $TESTJAVA/bin/javac -d $TESTCLASSES $TESTSRC/$@.java || exit 2
  46    $TESTJAVA/bin/java -classpath $TESTCLASSES $@        || exit 3
  47 }
  48 
  49 # Test GetMaxFileDescriptorCount if we are running on Unix
  50 case `uname -s` in
  51     SunOS | Linux )
  52        runOne GetMaxFileDescriptorCount
  53        ;;
  54     * )
  55        echo "Ignore test when not run on Solaris or Linux"
  56        exit 0
  57        ;;
  58 esac
  59 
  60 exit 0


  26 # @bug     4858522
  27 # @summary 
  28 # @author  Steve Bohne
  29 #
  30 # @run shell GetMaxFileDescriptorCount.sh
  31 #
  32 
  33 #Set appropriate jdk
  34 
  35 if [ ! -z "${TESTJAVA}" ] ; then
  36      jdk="$TESTJAVA"
  37 else
  38      echo "--Error: TESTJAVA must be defined as the pathname of a jdk to test."
  39      exit 1
  40 fi
  41 
  42 runOne()
  43 { 
  44    echo "runOne $@"
  45    $TESTJAVA/bin/javac -d $TESTCLASSES $TESTSRC/$@.java || exit 2
  46    $TESTJAVA/bin/java ${TESTVMOPTS} -classpath $TESTCLASSES $@        || exit 3
  47 }
  48 
  49 # Test GetMaxFileDescriptorCount if we are running on Unix
  50 case `uname -s` in
  51     SunOS | Linux )
  52        runOne GetMaxFileDescriptorCount
  53        ;;
  54     * )
  55        echo "Ignore test when not run on Solaris or Linux"
  56        exit 0
  57        ;;
  58 esac
  59 
  60 exit 0
< prev index next >