Using TestComplete script extensions technology, you can easily create custom operations for use in keyword tests, which will be added to the list in the Operations panel of the Keyword Test editor. These operations can perform any actions you need. For example, they can provide custom checkpoint types, perform some common tasks, be wrappers over frequently used scripting objects’ methods and so on.
The following topics describe the step-by-step procedures of creating a custom keyword test operation using the script extension technology:
1. Planning Operation's Functionality
3. Creating the Description File
4. Creating Operation's Fields
5. Creating Initialization Code
9. Creating Operation Setup Code
10. Defining Keyword Test Editor's Contents and Behavior
The code created in this tutorial are part of the AQAScriptExtensions.tcx file that is distributed with TestComplete. You can find it in the <TestComplete>\Bin\Extensions\ScriptExtensions folder. The AQAScriptExtensions package contains several extensions. The following files relate to our tutorial:
- laCode.js - Script unit.
- la-icon.bmp - The operation’s icon.
- laEditForm.aqfrm - The operation’s edit form.
- description.xml - Used to install the extension in TestComplete.
We will also use the AQAScriptExtensions.chm file that is located in the <TestComplete>\Bin\Extensions\ScriptExtensions folder.
Script Extensions Tutorials
Creating Keyword Test Operations