TestComplete supports testing of various Java controls. You can also modify project properties so that TestComplete recognizes your custom Java controls. The sections below describe how you can test Java controls in detail.
TestComplete can work with any Java control via a graphical user interface. Besides, TestComplete provides extended support for most of Java controls. It automatically associates them with special scripting test objects that contain supplementary methods and properties for working with the controls, for example, for selecting individual items and retrieving the item text.
A license for TestComplete Desktop module.
The Java Control Support plugin. It provides access to controls via special program objects. It also enables creating table checkpoints for controls that display data in a tabular form. For the full list of these controls, see About Tables Collection.
This plugin is installed and enabled automatically.
If you experience issues when working with the controls, select File | Install Extensions from the TestComplete main menu to check whether the plugin is active. If the plugin is not available, run the TestComplete installation in the Repair mode.
Java ver. 5 - 11.
Below is the full list of the Java controls for which TestComplete provides extended support.
Note that TestComplete provides support for the listed controls as well as for their descendants. However, to make this possible, you need to specify the class name of your inherited control in the corresponding group of the project’s Object Mapping options. For more information, see Object Mapping.
To command TestComplete to recognize your custom Java controls, open your project’s Object Mapping options and add the control’s class name to the corresponding subgroup of the Swing Controls group. The subgroup name corresponds to your custom control’s type. Once the control is mapped, it gets all the properties, methods and actions specific to the Java control of the corresponding type.
If the specified custom control does not fit the control’s type, then it may not properly respond to commands that TestComplete sends, so recording or playing back user actions over the tested control will cause errors.