running tests with jtreg

Stephen Bannasch stephen.bannasch at deanbrook.org
Tue Jan 11 12:10:59 PST 2011


I updated the wiki page: http://wikis.sun.com/display/OpenJDK/Mac+OS+X+Port with more detailed information about how to run 
tests using jtreg.

With the previous instructions I was getting this error:

Error: Cannot determine test suite from test (is TEST.ROOT missing?): /Users/stephen/dev/java/src/macosx-port/jdk/.

I tried running all the tests but stopped them before completion after about 15m -- not yet sure how long they will take.

Here's how I'm running a subset of tests, in this case it's the 342 jdk tests for java/lang:

$ cd <path-to-macosx-port-source>/jdk/
$ jtreg -jdk:../build/macosx-universal/j2sdk-bundle/1.7.0.jdk/Contents/Home/ -v:summary test/java/lang

I'm using the jtreg option -jdk to specify the JDK compiled in the macosx-port source directory.

Using the jtreg option: -v:summary reports on each test in the console and let's me know the tests are still running (useful 
when they take a long time).

This takes almost 7 minutes and the results report:

   Test results: passed: 267; failed: 75; error: 7

This is similar to the results I get running the same tests on the regular bsd-port source build from about 3 weeks ago:

   Test results: passed: 268; failed: 75; error: 6

I haven't used jtreg before -- if you have and see any mistakes please let me know.


More information about the macosx-port-dev mailing list