On Oct 22, 2005, at 12:37 AM, Andrew McIntyre wrote:

1 - For junit.jar - the instructions in BUILDING.txt are not clear as to what you are supposed to do with junit.jar.
<snip>
In general, compilepath.properties is reserved for JDK-related classes, jars containing java.*, javax.*, or direct dependencies. The new property for junit.jar should probably be called ${junit}, added to extrapath.properties, and the build.xml in java/ testing/.../functionTests/compatibility/build.xml should include $ {junit} in the appropriate classpath entries for the applicable <javac> tasks. Same for java/testing/.../functionTests/util/ build.xml and java/testing/.../jdbcapi/build.xml

Apparently sleepiness-induced blindness caused me to miss the (2) part in BUILDING.txt. Sorry about that. I've added a little bit to the description in BUILDING.txt, and fixed up the build files as described above. I moved the section on JUnit after the JDKs, because the default build target builds just the code for the product, and anyone interested in building the product but not the tests could get going with just the Ant, the JDKs, and the JDK extensions. Here's a patch with those files, and a blank master for CompatibilityTest.out that seemed to be missing from the original patch.

Attachment: 516build.diff
Description: Binary data



5 - if you are going to add jdbcapi/CompatibilityTest to derbynetmats.runall, then you should have a way for the current harness to gracefully fail / skip the test if all the requirements of CompatibilityTest are not met. As it is, it couldn't get jdbcapi/ CompatibilityTest to run, but it's likely that I missed something in my setup. At any rate, I can help with sorting out any issues with regards to getting the test to run as a part of the current test harness.

So, I got CompatibilityTest to run as a part of a suite within the current test harness, it turned out to be a classpath problem, but getting a NullPointerException for a classpath problem was a little unexpected. Printing appropriate messages if a driver can't be found would be nice. Try running:

java -Dframework=DerbyNet org.apache.derbyTesting.functionTests.harness.RunTest jdbcapi/ CompatibilityTest

without db2jcc.jar in your classpath and check the output in CompatibilityTest.tmp

It doesn't appear possible to run JDBCDriverTest standalone via Junit, since the driver name, database name, etc. is expected to be passed in from elsewhere. It might be useful to set appropriate defaults for these items if you wanted to run the test standalone via Junit.

I'll take a look at getting the full compatibility test to run with testscript.xml next week.

cheers,
andrew

Reply via email to