Java Recording Options
CukeTest provides a set of dedicated recording options for Java applications, allowing users to easily generate automated test scripts.
Note: Before recording Java applications, please enable Java Access Bridge.
Java Application
In the Application
field, you can specify the executable path of the Java application under test. When recording starts, if a path is specified, the application will be automatically launched. You can also leave it blank and manually start the application after recording begins via the menu Tools
-> Start Application...
. In either case, the corresponding Java application launch code will be generated in the recording script.
If you manually open the Java application before starting recording, no launch code will be generated in the script.
Command Line Arguments
In the Arguments
field, you can enter command-line arguments required to launch the target Java application. These arguments will be passed to the application and can include file paths, configuration options, or any other parameters supported by the application.
Slow Motion
The slow motion option is used to increase the delay between operations during playback. This is particularly useful for observing and debugging recorded scripts. Enabling this option adds the slowMo
setting to the generated script, with a default value of 1000 milliseconds (1 second per operation).
In the script, it can be set as follows:
const { RunSettings } = require("leanpro.common");
RunSettings.slowMo = 1000;
from leanproAuto import RunSettings
RunSettings.set({"slowMo": 1000})
Record to Existing Files
If you do not want to create a completely new recording but wish to append or continue recording on an existing recording, you can use this option. After selecting it, you need to specify the following two options in the popup window:
Model File: Append the control models generated during operations to the selected model file *.tmodel
instead of creating a new one.
Script File: Append the generated script to the selected script file (Python or JavaScript) instead of creating a new script file.
Capture Control Screenshots
Screenshots of the operated controls will be generated. These screenshots can be viewed in the Model Manager by clicking on each control (the container of the control will not be captured). This is useful for quickly locating the operated controls during debugging by reviewing the control screenshots.