Java Application Parameters Dialog

Applies to TestComplete 12.60, last modified on September 17, 2018

Use this dialog to add a Java or JavaFX application to the list of tested applications. To call the dialog, do the following:

  • Choose Generic Windows application on the Specify the Type of the Application Under Test page of the Create New Project wizard.

  • Click Add Java on the Add Your Tested Application to the Project page of the wizard.

Java Application Parameters Dialog

In the Java Virtual Machine to use box, specify which Virtual Machine executable will be used to run your Java application. You can either select the needed Java launcher from the drop-down list, or press the button and find the application using the standard Open File dialog.

The Specify application’s .jar file and Specify application’s entry point boxes specify how to launch the application:

  • The Specify application’s .jar file box specifies the path to the application’s .jar file. The .jar file must be created with the Main-Class header in the manifest, otherwise your application will fail to run.

  • The Specify application’s entry point box specifies the name of the main class which is your application’s entry point. If you are using this option, you should also specify the path to the .jar or .class file that holds the entry point main routine in the Class paths box.

In the Command-line arguments box, you can specify parameters that will be passed to the Java application.

In the Environment options box, you can specify the command-line options that will be passed to the Java Virtual Machine.

In the Working folder box you can specify the working folder for the application run. You can either type the desired folder name or click the ellipsis button and choose the desired folder in the ensuing Browse for Folder dialog.

Use the Class paths box to specify the paths to Java classes used in the application. If you are launching your application by specifying its entry point, you should also specify the location of the .jar or .class file that holds the entry point routine in this list.

To add the folder that contains Java classes to the Class paths list, click the Add Directory button, select the needed folder from the resulting Browse for Folder dialog and click OK. To add the .jar file containing Java classes to the list, click Add JAR File and then select the desired file from the subsequent Select JAR File dialog. To remove the selected class path from the list, press Remove. To change the position of the selected class path in the list, use the Move Up and Move Down buttons.

You can control the format used to specify the paths to the application’s .jar file or to the working folder. The target path can be specified by using the absolute path, the relative path or environment variables (if the path includes any standard system path for which environment variables are set). You can click the drop-down button in the corresponding box and select the needed representation in the drop-down list. See Using Variables in Tested Application Paths.

To close the dialog, click OK. TestComplete will add the specified Java application to the list of tested applications. Cancel will close the dialog discarding any changes.

See Also

Testing Java Applications - Overview
About Tested Applications
Adding Java and JavaFX Applications to the List of Tested Applications

Highlight search results