Borland Software Water System silk perforator java explorer 2006 release 2 Manuel D’Utilisation

Page de 110
SilkPerformer Java Explorer User Guide
99
7  E
XPORTING
 P
ROJECTS
JUnit Test Cases
Java Profile Settings will be saved in the SilkPerformer project file, so the same 
Java Runtime and classpath settings will be used in SilkPerformer as in Java 
Explorer. This enables the Java test class to be compiled in the SilkPerformer 
GUI. When starting a load test or a try script run, the Java compiler is 
automatically invoked, just like the BDL compiler.
Exported Files:
SilkPerformer project file (.ltp)
SilkPerformer script file (.bdf)
Java test script (.java)
Working with multiple 
agents
Normally, load testing with SilkPerformer is done via multiple agents. For the 
Java Framework to run smoothly, the following issues must be addressed: 
Install a JDK on each agent machine. The version of the JDK should be 
at least the same version (or higher) as that used for the Java Explorer 
project.  
The JDK must be installed in the same directory on each agent machine. 
Make sure that the same classpath is available on each agent machine. 
For example, when load testing WebLogic EJBs, the package 
weblogic.jar must be on each agent machine in the same directory. The 
same applies to EJB stubs. 
JUnit Test Cases
Java Explorer enables you to export JUnit TestSuites. Export generates a Java 
test class for JUnit and two batch files for compiling and running the test class. 
JUnit is a widely used regression testing framework. For details, visit: 
www.junit.org/
Procedure  To export a JUnit testsuite:
1
Go to Java Explorer’s Export menu and select JUnit Test Case.
2
The File name of the test class generated by the export can be set in 
project settings. The JUnit Export Wizard displays the name (read-only) 
and provides a button (...) that opens the project settings with the 
appropriate tab pre-selected.
3
Select the target directory using the browse button.