Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4863613

TEST_BUG: Regtest sun/nio/cs/EUCTWBufferBoundaryDecodeTest.java writes to TESTSR

    XMLWordPrintable

    Details

      Description

      Name: vsR10238 Date: 05/13/2003


      Filed By : J2SE-SQA [###@###.###
      JDK : JDK1.4.2-b22
      Testbase : Regression-test
      Falling test[s]:
      sun/nio/cs/EUCTWBufferBoundaryDecodeTest.java

      The sun/nio/cs/EUCTWBufferBoundaryDecodeTest.java test from the regression test suite for JDK1.4.2-b22
      fails because it tries to write to test source directory which should be read-only.
      This test should better use the scratch subdirectory for output as other tests do.

      Here is a part of the test:

             final String outFileName = "eucTWmsg.out";
             File outputFile = new File(System.getProperty("test.src"), outFileName);

      Test source location:
      =====================
      /java/re/jdk/1.4.2/promoted/latest/ws/j2se/test/sun/nio/cs/EUCTWBufferBoundaryDecodeTest.java


      How to reproduce:
      =================
      Run the following script (you may need to change its variables)
       
      --- script start ---
      #!/bin/sh
                                                                                                                                 
      RESULT_DIR=`pwd`
      WORK_DIR=$RESULT_DIR/workDir/test
      REPORT_DIR=$RESULT_DIR/reportDir
      JT_HOME="/net/jtgb4u4c/export/sail16/jct-tools/3.1.2"
      JAVA_HOME="/java/re/jdk/1.4.2/promoted/rc/b22/binaries/solaris-sparc"
      TEST_BASE_PATH="/java/re/jdk/1.4.2/promoted/rc/b22/ws/j2se/test"
                                                                                                                                 
      TESTWITH=$JAVA_HOME
      TESTJAVA=$JAVA_HOME
                                                                                                                                 
      JTOPTS="-server"
      TESTVMOPTS="-server"
                                                                                                                                 
      CLASSPATH="$JT_HOME/classes:$JT_HOME/lib/javatest.jar:$JT_HOME/lib/jtreg.jar:$JT_HOME/jemmy/jemmy.jar"
                                                                                                                                 
      export JAVA_HOME
      export JT_HOME
      export TESTWITH
      export CLASSPATH
                                                                                                                                 
      mkdir -p $WORK_DIR/scratch 2>&1
      mkdir -p $WORK_DIR/jtData 2>&1
      mkdir -p $REPORT_DIR 2>&1
                                                                                                                                 
      #rm $WORK_DIR/jtData/ResultCache.jtw 2>&1
                                                                                                                                 
      cd $WORK_DIR/scratch
                                                                                                                                 
      $JAVA_HOME/bin/java -cp $CLASSPATH $JTOPTS \
      -DenvVars=TESTJAVAHOME=$JAVA_HOME,TESTVMOPTS=$TESTVMOPTS,DISPLAY=:0,\
      HOME=$HOME/.regtest,PATH=/bin:/usr/bin,CPAPPEND=$JT_HOME/jemmy/jemmy.jar,\
      TZ=,LC_ALL=en_US,LC_CTYPE=en_US,LANG=en_US,LPDEST= \
      -DDISPLAY=:0 -DlocalHost="JCC-ITANIUM-01" -Dprogram=jtreg \
      com.sun.javatest.regtest.Main \
      -a -v default -batch \
      -params \
      -w "$WORK_DIR" -r "$REPORT_DIR" -t "$TEST_BASE_PATH" "$TEST_BASE_PATH/sun/nio/cs/EUCTWBufferBoundaryDecodeTest.java"

      --- script end ---


      Test output (jtr part):
      =======================
      ----------System.err:(16/1153)----------
      java.io.FileNotFoundException: /net/jtgb4u4c/export/sail16/Regression/test/1.4.2/sun/nio/cs/eucTWmsg.out (Permission denied)
              at java.io.FileOutputStream.open(Native Method)
              at java.io.FileOutputStream.<init>(FileOutputStream.java:179)
              at java.io.FileOutputStream.<init>(FileOutputStream.java:131)
              at EUCTWBufferBoundaryDecodeTest.main(EUCTWBufferBoundaryDecodeTest.java:38)
              at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
              at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
              at java.lang.reflect.Method.invoke(Method.java:324)
              at com.sun.javatest.regtest.MainWrapper$MainThread.run(MainWrapper.java:82)
              at java.lang.Thread.run(Thread.java:534)

      JavaTest Message: Test threw exception: java.io.FileNotFoundException: /net/jtgb4u4c/export/sail16/Regression/test/1.4.2/sun/nio/cs/eucTWmsg.out (Permission denied)
      JavaTest Message: shutting down test

      STATUS:Failed.`main' threw exception: java.io.FileNotFoundException: /net/jtgb4u4c/export/sail16/Regression/test/1.4.2/sun/nio/cs/eucTWmsg.out (Permission denied)
      result: Failed. Execution failed: `main' threw exception: java.io.FileNotFoundException: /net/jtgb4u4c/export/sail16/Regression/test/1.4.2/sun/nio/cs/eucTWmsg.out (Permission denied)


      test result: Failed. Execution failed: `main' threw exception: java.io.FileNotFoundException: /net/jtgb4u4c/export/sail16/Regression/test/1.4.2/sun/nio/cs/eucTWmsg.out (Permission denied)





      Specific machine info:
      ======================
      Hostname: JCC-ITANIUM-01
      OS: RedHat Linux 2.1 Adv. Server
      Hostname: JCC-ITANIUM-02
      OS: Windows 2003 Enterprise



      ======================================================================

        Attachments

          Activity

            People

            Assignee:
            sherman Xueming Shen
            Reporter:
            vshsunw Vsh Vsh (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: