Jigsaw test failures

Mandy Chung mandy.chung at oracle.com
Wed Jan 5 10:03:51 PST 2011


  It's a test bug that compares an original class file with a 
"pack-then-unpack' class file that is not the same as the original file 
as it's modified during the pack200 compression process.

Before the fix in pack200 for (in JDK 7 b100):
    6712743: pack200: should default to 150.7 pack format for classfiles 
without any classes.
    Changeset: http://hg.openjdk.java.net/jdk7/tl/jdk/rev/43dfa39686a1

pack200 doesn't recognize class files of version 51.0 and thus doesn't 
do the compression and thus the class files match even after pack200.  I 
missed this test failure when updating jigsaw repos with the recent jdk 
7 builds since these tests failed with a different error before the merge:
    keytool error: java.security.KeyStoreException: JKS not found

Here is the webrev for the test fix:
    http://cr.openjdk.java.net/~mchung/jigsaw/webrevs/test-fix.webrev.00/

There are pack200 regression tests that verify if pack200 generates 
correct class files.  In addition, using the jdk-module-image to build 
and run tests also verify the class files installed by jmod.  I think 
byte-by-byte class file comparison isn't necessary in these tests.  So 
ModuleFormatTest01.java is modified just to verify the ClassFile header 
(the first 10 bytes).

Sean,
    Can you review the webrev?

Thanks
Mandy

On 01/03/11 13:01, Sean Mullan wrote:
> There are a few jigsaw regression test failures:
>
>     * org/openjdk/jigsaw/cli/ModuleFormatTest01.sh
>     * org/openjdk/jigsaw/cli/jmod-signed.sh
>     * org/openjdk/jigsaw/cli/signed-module.sh
>
> The last one is due to the cacerts file being empty. We have a fix 
> coming for that.
>
> However, the previous two appear to be the same failure and is caused 
> when it compares the bytes of one of the classes in an installed 
> module with the bytes in the module file (I think). This is the stack 
> trace from the ModuleFileFormatTest01.sh test:
>
> java.lang.RuntimeException: file compare failed 1
>     at ModuleFormatTest01.compare(ModuleFormatTest01.java:472)
>     at ModuleFormatTest01.compare(ModuleFormatTest01.java:407)
>     at ModuleFormatTest01.compare(ModuleFormatTest01.java:425)
>     at ModuleFormatTest01.compare(ModuleFormatTest01.java:448)
>     at 
> ModuleFormatTest01.doTestSingleClassModule(ModuleFormatTest01.java:114)
>     at 
> ModuleFormatTest01.testSingleClassModule(ModuleFormatTest01.java:93)
>     at ModuleFormatTest01.test(ModuleFormatTest01.java:301)
>     at ModuleFormatTest01.run(ModuleFormatTest01.java:54)
>     at ModuleFormatTest01.main(ModuleFormatTest01.java:49)
> Exception in thread "main" java.lang.Exception: 1/2 tests failed
>     at ModuleFormatTest01.run(ModuleFormatTest01.java:62)
>     at ModuleFormatTest01.main(ModuleFormatTest01.java:49)
> result: Failed. Execution failed: exit code 1
>
> Has anyone looked at this more closely?
>
> Thanks,
> Sean




More information about the jigsaw-dev mailing list