About Component Testing for Java

The Component Testing for Java feature of Test RealTime provides a unique, fully automated, and proven solution for Java unit testing, dramatically increasing test productivity.

Component Testing for Java uses the standard JUnit testing framework for test harness development. There are two ways of using the JUnit test harness:

How Component Testing for Java Works

When a test node is executed, Test RealTime compiles both the .java test scripts and the source under test. This preprocessing creates a .tsf file. The resulting source code generates a test driver.

If any Runtime Analysis tools are associated with the test node, then the source code is also instrumented with the Java Instrumentor (javi) tool.

The test driver, TDP, stubs and dependency files all make up the test harness.

The test harness interacts with the source code under test and produces test results. Test execution creates a .tdf file.

The .tsf and .tdf files are processed together the Component Testing Report Generator (javapostpro). the output is the .xrd report file, which can be viewed and controlled in the Test RealTime GUI.

Of course, these steps are mostly transparent to the user when the test node is executed in the Test RealTime GUI.

 

To learn about

See

Rational's implementation of the JUnit framework

About JUnit

Building a JUnit Test Harness

Java Test Harness

Using Component Testing for Java with Java 2 Platform, Mobile Edition (J2ME)

J2ME Specifics

Creating a new JUnit test node in Test RealTime

Component Testing Wizard

Importing an existing JUnit test harness into Test RealTime

Importing a JUnit Test Campaign

How Component Testing for Java handles stubs in Java

Java Stubs

Interpreting a test report produced by Component Testing for Java

Understanding Java Test Reports

Interpreting a UML sequence diagram produced by Component Testing for Java

Understanding Java Component Testing UML Sequence Diagrams

 

Related Topics

Automated Testing | Runtime Analysis