JTReg tests results on other ports
Scott Palmer
swpalmer at gmail.com
Wed Sep 28 04:29:34 PDT 2011
If a particular version is required that should be included too. I tried junit-4.8.2.jar, placing it in the jtreg/lib directory as instructed. The tests don't compile.
e.g.:
----------System.err:(56/3093)----------
/Users/scott/dev/openjdk/jdk/test/java/lang/String/q0001BasicString.java:31: error: package junit.framework does not exist
import junit.framework.*;
^
/Users/scott/dev/openjdk/jdk/test/java/lang/String/q0001BasicString.java:33: error: cannot find symbol
public class q0001BasicString extends TestCase {
^
symbol: class TestCase
/Users/scott/dev/openjdk/jdk/test/java/lang/String/q0001BasicString.java:73: error: cannot find symbol
public static Test suite() {
Scott
On 2011-09-27, at 10:54 PM, Jonathan Gibbons wrote:
> Scott,
>
> You need to install a copy of junit.jar in the jtreg lib/ directory, or otherwise make it known to jtreg. For licensing reasons, we can no longer redistribute a copy of junit.jar with jtreg itself.
>
> If I recall correctly, you can also specify -nojunit to prevent jtreg from trying to run tests that would otherwise require JUnit.
>
> I note your comment that the FAQ on the openjdk website is out of date. I'll update it. The version of the FAQ bundled with jtreg should be more informative.
>
> -- Jon
>
>
> On 09/27/2011 07:38 PM, Scott Palmer wrote:
>> The issue is this error which occurs quite a bit when I try to run the tests:
>>
>> JUnit not available: see the FAQ or online help for details
>>
>> Except the only mention in the FAQ (http://openjdk.java.net/jtreg/faq.html) is:
>>
>>
>> 1.13. Why not use JUnit?
>>
>> JUnit was not around when we started writing tests for JDK. And, the test tag specification has been specifically designed for testing JDK, with support for testing applets, command-line interfaces, and so on, as well as simple API tests.
>>
>> And by now, there are many thousands of tests written for jtreg, so it would not be practical to convert to JUnit.
>>
>>
>>
>> Not exactly helpful.
>>
>> Scott
>>
>>
>> On 2011-09-27, at 9:31 PM, Jonathan Gibbons wrote:
>>
>>> jtreg -help gives info about all the basic options. You can also see the info in a browser with jtreg -onlinehelp
>>>
>>> In its simplest form, you want
>>>
>>> jtreg -jdk:/JDK_TO_TEST TESTS/
>>>
>>> For example, if you're in the root of a forest for which you have completed a build, it will be something like:
>>>
>>> jtreg -jdk:build/linux-i586/j2sdk-image jdk/test/
>>>
>>> But, that probably runs more tests than you want, and includes some manual tests, and some that may fail,
>>> so you might also want to take advantage of the rules in test/Makefile.
>>>
>>> For example, if you're in the root of a forest for which you have completed a build, it will be something like:
>>>
>>> cd test; make all
>>>
>>> -- Jon
>>>
>>>
>>>
>>> On 09/27/2011 06:13 PM, Scott Palmer wrote:
>>>> Is there a document somewhere that explains how to setup jtreg? I gave it a try a month ago, googled a bit, but found it was basically undocumented.
>>>>
>>>> Scott
>>>>
>>>> On 2011-09-27, at 8:11 PM, David Durrence wrote:
>>>>
>>>>> I have run most of the tests listed in this email and for the most part, the test cases are passing for me when I run those tests (on both 10.6.8 and 10.7.1). Under what circumstances are the tests failing? Here are some of my results:
>>>>>
>>>>> javaqa8:jdk mrj$ /Volumes/Data/mySVN/jtreg/linux/bin/jtreg -jdk:/Library/Java/JavaVirtualMachines/1.7.0.jdk/Contents/Home/ -v:summary test/java/lang/instrument/
>>>>> Passed: java/lang/instrument/appendToClassLoaderSearch/CircularityErrorTest.sh
>>>>> Passed: java/lang/instrument/appendToClassLoaderSearch/ClassUnloadTest.sh
>>>>> Passed: java/lang/instrument/appendToClassLoaderSearch/run_tests.sh
>>>>> Passed: java/lang/instrument/BootClassPath/BootClassPathTest.sh
>>>>> Passed: java/lang/instrument/PremainClass/InheritAgent0001.java
>>>> ...
>>>>
>
More information about the macosx-port-dev
mailing list