README contains basic information about SigTest tool
Version 2.0. See the SigTest Tool User's Guide for more information.
The SigTest tool assists a developer in developing and running a signature test to be included in a finished test suite.
It operates based on the following principles:
The following environment settings and components must be set in order to run SigTest tool:
The SigTest tool, version 2.0 release is the initial open source distribution. The open source release is based on Sun Microsystem's SigTest tool, version 2.0.
To install the SigTest tool, unzip the distribution into a directory of your choice.
Unpacking the Zip bundle installs subdirectories under the base installation directory as described in Release Contents. See the SigTest Tool 2.0 User's Guide for detailed information on how to configure the SigTest tool for your system.
This section lists the components under the base subdirectory structure (
that is created when you unzip the SigTest tool distribution archive during
| ||The SigTest tool README document (this document).|
||The entire class archive that is necessary to run all the tool commands used to develop a signature test.|
|| A subset of the files in the
||The classes necessary to create the remote class loader used to develop distributed extensions. These classes are Connected Device Configuration 1.0 compatible.|
||Contains the sample test suite files used for the SigTest tool usage examples.|
||Contains text describing license and copyrights that apply to this project.|
The SigTest tool operates from the command line with the following commands.
Setupcommand creates a signature file from either an API defined by a specification or a reference API implementation. A signature file is a text representation of the set of public and protected features provided by an API. Test suite developers include it in a finished test suite as a signature reference for comparison to the technology implementation under test.
SignatureTestcommand compares the reference API represented in the signature file to the API under test and produces a report. This is the actual test that becomes part of a finished test suite.
SetupAndTestcommand runs only in static mode, described later, to execute the
SignatureTestcommands in one operation.
Mergecommand creates a combined signature file from several signature files representing different Java APIs in one Java runtime environment according to the JSR 68 rules.
This section contains simple examples showing how to start the
SigTest tool from the command line using the
SignatureTest command line options. See System Requirements for initial setup.
Example 1: The following command line runs
Setup command to create a signature file named
java -cp sigtestdev.jar com.sun.tdk.signaturetest.Setup -static
-classpath $JAVA_HOME/jre/lib/rt.jar -filename result.sig -package
Example 2: The following command line runs
SignatureTest command to manually run a signature test:
java -cp sigtest.jar com.sun.tdk.signaturetest.SignatureTest
-static -filename result.sig -classpath $JAVA_HOME/jre/lib/rt.jar
This section describes the SigTest tool operating modes and report messages.
The following two run modes are available during command execution, each associated with how the class descriptions are examined and retrieved:
SignatureTestcommands, it uses reflection to examine API classes and retrieve information about them. The reflection mode is of greatest advantage when the API to be analyzed has no external class files.
-staticoption, the tool parses only the class files listed in the
-classpathcommand-line argument. You normally use static mode when a reflection mechanism is not supported, or in a security-constrained environment that disallows checking required attributes. Static mode is useful for testing specified classes in another runtime environment. The
Setup and SetupAndTestcommand run only in static mode.
Report messages can (by default) be either sorted or unsorted. They contain the following types of information:
See the SigTest Tool Version 2.0 User's Guide for hands-on procedural examples of running the tool.
Copyright © 2008 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms. .