background image
<< Pre and Post-conditions | Java Testing Overview >>
<< Pre and Post-conditions | Java Testing Overview >>

Component Testing for Java

Automated Testing
Comments and Prints
COMMENT and PRINT statements generate a white note, attached to the
corresponding instance.
Messages
Messages can represent either a RUN or a CALL statement, or a native code stub call,
as shown below:
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:
·
You use the Test RealTime GUI to set up your test campaign, write a JUnit test
script, run your tests and view the results
·
You import an existing JUnit test harness into the Test RealTime GUI.
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 features 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.
175