JT Harness Build Instructions

In order to contribute code to the project you must have a contributor role. See Mobile & Embedded Community Governance for information about the different community roles.

For a description of how the JT harness repository is organized, read JT Harness Repository Structure.

The JT Harness Developer's Guide describes how the source code is organized and provides important information for developers who want to modify the code.

The JT Harness Source Code Description describes how the JT harness source code is organized.

Note: If you are viewing these instructions on the web site, they apply to the release in development on the repository trunk. At the end of every release cycle, these build instructions are archived with the rest of the web site in the www/ directory in the tagged branch of the web site that corresponds to that release. If you are building an earlier version of the software please refer to the instructions archived with the tag that corresponds with that release.

 

Table of Contents

 

Requirements

The JT harness build requires the technologies listed in the following table.

TechnologyWhere to Get ItNotes
Ant version 1.6.1 or laterhttp://ant.apache.org/Ant must Java 6 or later. Use the ant -diagnostics command to verify the version.
ASM Java bytecode manipulation framework v3.1http://asm.objectweb.org/Required for compilation only and is not required at run time.
JavaHelp software version 2.0_02 or laterhttp://javahelp.java.net

Specify a build variable in the local.properties file to point to the jh.jar library. See Configure and Run the Build for details.

JavaHelp software version 2.0_02 may be used, with the following minor limitation. On systems that have two separate displays (typically on X11 systems), the help viewer may default to the first screen, which may not be the screen on which you are running the harness. For example, if the harness is on screen :0.1, the help viewer appears on screen :0.0.

Java SE version 6 or laterhttp://java.sun.com/javase/index.jsp 
Java Communications 3.0 APIhttp://java.sun.com/products/javacomm/index.jspCurrently, implementations are only available for Solaris SPARC, Solaris x86, and Linux x86. Required for compilation only and is not required at run time.
JUnit 4.4 libraryhttp://junit.orgJUnit 4.5 has not been tested with JT harness and is therefore not supported. Required for compilation only and is not required at run time.
Servlet libraries (javax.servlet)https://glassfish.dev.java.net

Required for compilation only and is not required at run time. Used for the compilation of include servlet.

 

 

Checking out the source

The JTHarness tool repository is located on OpenJDK servers, in the CodeTools Project.  It is stored in mercurial vcs, and can be uploaded from mercurial via the following command:

  % hg clone http://hg.openjdk.java.net/code-tools/jtharness

 

Configure and Run the Build

The following steps describe how to build the JT harness. These instructions assume that your JT harness local working copy is named JTHarness.

  1. Set up and configure the JDK.
The output of the build (build distribution) contains the following two sub-directories:

 

Run the JT Harness

You can run the JT Harness in the following ways:

Refer to the sample test suites in the examples directory to see how JT harness can be used in a test suite.

Additional Build Targets

The following additional targets are available. You might wish to identify these targets to your IDE (for example, NetBeans).

 

Build TargetDescription
cleanRemoves the entire build distribution directory.
buildCreates and tests the build distribution.
build-examplesBuilds the example test suites packaged with the source. This target automatically builds the core harness first.
javadocCreates the API documentation.
testTests an existing build distribution.
runRuns the JT harness.