-
Bug
-
Resolution: Fixed
-
P4
-
1.4.2, 5.0
-
b16
-
generic, x86, sparc
-
generic, linux, solaris_8, windows_2000
-
Verified
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-2063689 | 5.0 | Ian Little | P4 | Closed | Fixed | tiger |
Name: iaR10016 Date: 01/19/2003
Filed By : J2SE-SQA [###@###.###
JDK : JDK1.4.2-b12, JDK1.4.1, JDK1.4.0
Testbase : RegTest-test
Platform[s] : all
Falling test: sun/nio/cs/EUCTWBufferBoundaryDecodeTest.java
Regtest-test test sun/nio/cs/EUCTWBufferBoundaryDecodeTest.java fails with error when
running with harness. The test passes if it is executed manually.
The problem is that class EUCTWBufferBoundaryDecodeTest is not declared as "public",
so harness can not get access to it.
Here is a code fragment of EUCTWBufferBoundaryDecodeTest.java:
--------- EUCTWBufferBoundaryDecodeTest.java ---------
...
015> class EUCTWBufferBoundaryDecodeTest {
016> public static void main(String[] argv) throws Exception {
...
------------------------------------------------------
If I change line 15 to "public class EUCTWBufferBoundaryDecodeTest {"
the test works fine.
Test source location:
=====================
/java/re/jdk/1.4.2/promoted/latest/ws/j2se/test/sun/nio/cs/EUCTWBufferBoundaryDecodeTest.java
jtr file location:
==================
/net/jtgb4u4c.sfbay/export/sail15/results/mantis/b12/regtest/win32/winXP_linux-16/workDir/test/sun/nio/cs/EUCTWBufferBoundaryDecodeTest.jtr
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/linux-15/export/home/java/jct"
JAVA_HOME="/net/linux-15/export/home/java/jdk1.4.2/linux"
TEST_BASE_PATH="/net/linux-15/export/home/java/regtest/test"
export CLASSPATH="$JT_HOME/classes:$JT_HOME/lib/javatest.jar:$JT_HOME/lib/jtreg.jar"
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 -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:(10/742)----------
java.lang.IllegalAccessException: Class com.sun.javatest.regtest.MainWrapper$MainThread can not access a member of class EUCTWBufferBoundaryDecodeTest with modifiers "public static"
at sun.reflect.Reflection.ensureMemberAccess(Reflection.java:57)
at java.lang.reflect.Method.invoke(Method.java:317)
at com.sun.javatest.regtest.MainWrapper$MainThread.run(MainWrapper.java:82)
at java.lang.Thread.run(Thread.java:536)
JavaTest Message: Verify that the class defining the test is
JavaTest Message: declared public (test invoked via reflection)
STATUS:Error.java.lang.IllegalAccessException: Class com.sun.javatest.regtest.MainWrapper$MainThread can not access a member of class EUCTWBufferBoundaryDecodeTest with modifiers "public static"
result: Error. java.lang.IllegalAccessException: Class com.sun.javatest.regtest.MainWrapper$MainThread can not access a member of class EUCTWBufferBoundaryDecodeTest with modifiers "public static"
test result: Error. java.lang.IllegalAccessException: Class com.sun.javatest.regtest.MainWrapper$MainThread can not access a member of class EUCTWBufferBoundaryDecodeTest with modifiers "public
static"
======================================================================
Filed By : J2SE-SQA [###@###.###
JDK : JDK1.4.2-b12, JDK1.4.1, JDK1.4.0
Testbase : RegTest-test
Platform[s] : all
Falling test: sun/nio/cs/EUCTWBufferBoundaryDecodeTest.java
Regtest-test test sun/nio/cs/EUCTWBufferBoundaryDecodeTest.java fails with error when
running with harness. The test passes if it is executed manually.
The problem is that class EUCTWBufferBoundaryDecodeTest is not declared as "public",
so harness can not get access to it.
Here is a code fragment of EUCTWBufferBoundaryDecodeTest.java:
--------- EUCTWBufferBoundaryDecodeTest.java ---------
...
015> class EUCTWBufferBoundaryDecodeTest {
016> public static void main(String[] argv) throws Exception {
...
------------------------------------------------------
If I change line 15 to "public class EUCTWBufferBoundaryDecodeTest {"
the test works fine.
Test source location:
=====================
/java/re/jdk/1.4.2/promoted/latest/ws/j2se/test/sun/nio/cs/EUCTWBufferBoundaryDecodeTest.java
jtr file location:
==================
/net/jtgb4u4c.sfbay/export/sail15/results/mantis/b12/regtest/win32/winXP_linux-16/workDir/test/sun/nio/cs/EUCTWBufferBoundaryDecodeTest.jtr
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/linux-15/export/home/java/jct"
JAVA_HOME="/net/linux-15/export/home/java/jdk1.4.2/linux"
TEST_BASE_PATH="/net/linux-15/export/home/java/regtest/test"
export CLASSPATH="$JT_HOME/classes:$JT_HOME/lib/javatest.jar:$JT_HOME/lib/jtreg.jar"
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 -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:(10/742)----------
java.lang.IllegalAccessException: Class com.sun.javatest.regtest.MainWrapper$MainThread can not access a member of class EUCTWBufferBoundaryDecodeTest with modifiers "public static"
at sun.reflect.Reflection.ensureMemberAccess(Reflection.java:57)
at java.lang.reflect.Method.invoke(Method.java:317)
at com.sun.javatest.regtest.MainWrapper$MainThread.run(MainWrapper.java:82)
at java.lang.Thread.run(Thread.java:536)
JavaTest Message: Verify that the class defining the test is
JavaTest Message: declared public (test invoked via reflection)
STATUS:Error.java.lang.IllegalAccessException: Class com.sun.javatest.regtest.MainWrapper$MainThread can not access a member of class EUCTWBufferBoundaryDecodeTest with modifiers "public static"
result: Error. java.lang.IllegalAccessException: Class com.sun.javatest.regtest.MainWrapper$MainThread can not access a member of class EUCTWBufferBoundaryDecodeTest with modifiers "public static"
test result: Error. java.lang.IllegalAccessException: Class com.sun.javatest.regtest.MainWrapper$MainThread can not access a member of class EUCTWBufferBoundaryDecodeTest with modifiers "public
static"
======================================================================
- backported by
-
JDK-2063689 TEST_BUG RegTest-test sun/nio/cs/EUCTWBufferBoundaryDecodeTest.java fails
- Closed