Test Design StudioGo to Previous Topic: New File Item TemplatesGo to Next Topic: Documenter

External Tools

Test Design Studio allows you to easily incorporate external tools and applications. Any application that can be executed using command-line syntax can be added as an external tool.

External Tools

An external tool is a special configuration for any command-line based application. Almost all applications can be executed from the command-line. Some applications even provide special command-line arguments that can be specified to control how the application behaves. An external tool allows you to configure an application to be executed and pass command-line arguments.

External Tool Groups

External tool groups are used to organize external tools into groups. Use of external tool groups are optional. When an external tool is defined, that tool appears in the menu system under the Tools menu. As the number of external tools increase, so will the number of items appearing in the menu system. When an external tool group is created, a sub-menu is generated for each tool group that will contain the menu items for the external tools in that group. This reduces the number of items on the standard Tools menu and groups them under appropriate sub-menus.

External Tools Wizard

External Tools are configured using the External Tools Wizard. This wizard can be opened by selecting Tools -> External Tools from the main menu.

Welcome Screen

From this screen you have four options:
OptionDescription
Add a new external tool Use this option to quickly add an external tool. The next page displayed will be the Add/Modify External Tool - Tool Group page.
View or change existing external tools Use this option to view existing tools, change an existing tool, or add a new tool. The next page displayed will be the View External Tools page.
Add a new tool group Use this option to quickly add an external tool group. The next page displayed will be the Add/Modify External Tool Group page.
View or change existing tool groups Use this option to view existing tool groups, change an existing tool group, or add a new tool group. The next page displayed will be the View External Tool Groups page.

Select the desired option and click the Next button.

External Tools

Add/Modify External Tool - Tool Group

This page is used to identify which, if any, tool group the external tool will be contained within. If you do not wish to use a tool group, select the Do not include in a tool group option. Otherwise, select the Include in the following tool group option and select the desired group from Group Name drop-down list. If no groups are displayed, you will first need to add the tool group.

When your selection is complete, click the Next button to proceed to the Add/Modify External Tool - Tool Details page.

Add/Modify External Tool - Tool Details

This page is used to provide the details of how the external tool will be executed.
FieldDescription
TitleSpecifies the title to be used for the external tool. The title will be displayed as the caption of the menu item for this external tool.
Command This is the full path to the application file to be executed (typically with the .exe file extension). You can use the ... browse button to the right of the Command textbox to browse for the specific file.
Use Specific Icon By default, all external tools will use an icon derived from the Command specified for the tool. If you want to specify a different icon for use by the tool, check the Use Specific Icon box and then click the ... browse button to the right of the checkbox. You will then be prompted to specify a file with a EXE or ICO extension from which the icon for the tool will be derived.
Arguments Specify the command-line arguments to be passed when the tool is executed. The syntax of command-line arguments varies with the application, so consult your application documentation for information on the available arguments and their syntax.
Tip:    Special replacement parameters may be used in the arguments list that will change based on the context under which the external tool is executed. See the table of replacement parameters below.
Prompt for ArgumentsWhen this option is checked, you will be presented with a dialog to confirm the arguments of an external tool immediately before it is executed.
Initial Directory Specifies the full path to the initial directory to be used when executing the tool. Most application do not require this option and will execute under the directory of the file specified in the Command field.
Assign to Shortcut There are 24 commands that can be associated with the execution of an external tool, and those commands can be customized to respond to specific keyboard shortcuts. Use this option to specify which, if any, external command keyboard shortcut should be assigned to this external tool.

Replacement Parameters for Arguments

When an external tool is executed, the context of the application is taken into consideration. If a file selection is active in the application, the replacement parameters below will be available. If a specific editor is open and has focus when the external tool is executed, the file being edited will determine the replacement parameters. Otherwise, the currently selected file in the Solution Explorer tool window will be used for the replacement parameters.

If the file selection is determined, the parameters in the argument list will be replaced by the corresponding value represented by that parameter (based on the current file). If no file selection can be determined, these replacement parameters will have no impact on the argument list.

Replacement Parameter Description
$(ItemPath) Item Path. The full path to the file including directory and file name.
$(ItemDir) Item Directory. The full path to the directory where the file is located. Does not include the file name. Example: C:\Documents\Readme.txt will return C:\Documents
$(ItemFileName) Item File Name. The full name of the file only. Does not include directory. Example: C:\Documents\Readme.txt will return Readme.txt
$(ItemExt) Item Extension. The extension of the file including the preceding "." character. Example: C:\Documents\Readme.txt will return .txt
$(CurLine) Current Line. (Available only when an editor is active) The current line position of the caret in the editor.
$(CurCol) Current Column. (Available only when an editor is active) The current column position of the caret in the editor.
$(CurPos) Current Position. (Available only when an editor is active) The current character position of the caret in the editor.
$(CurText) Current Text. (Available only when an editor is active) The current text selection in the editor. If no selection is active, the current word under the caret will be used.
$(QualityCenterServer) ALM Server. (Available only when an ALM file is active) The URL of the HPE Application Lifecycle Management server.
$(QualityCenterDomain) ALM Domain. (Available only when an ALM file is active) The name of the HPE Application Lifecycle Management domain.
$(QualityCenterProject) ALM Project. (Available only when an ALM file is active) The name of the HPE Application Lifecycle Management project.
$(QualityCenterPath) ALM Path. (Available only when an ALM file is active) The full path of the file as stored in the HPE Application Lifecycle Management project.
$(QualityCenterUsername) ALM User Name. (Available only when an ALM file is active) The user name used to login to the HPE Application Lifecycle Management project.
$(QualityCenterPassword) ALM Password. (Available only when an ALM file is active) The password used to login to the HPE Application Lifecycle Management project.
$(ProjectDir) Project Directory. The full path to the directory where the project file is located.
$(ProjectFileName) Project File Name. The full name of the project configuration file only.
$(ProjectFolder) Project Folder. The full path to the project folder where a file is located.
$(SolutionDir) Solution Directory. The full path to the directory where the solution file is located.
$(SolutionFileName) Solution File Name. The full name of the solution configuration file only.
$(InstallDir) Installation Directory. The full path to the installation directory of the application.
$(AppHandle) Application handle (hWnd). This is the unique Windows handle that has been assigned to the current session of the application.
Tip:    Please contact Patterson Consulting if you feel additional replacement parameters are necessary.

When your selection is complete, click the Next button to proceed to the Add/Modify External Tool - Advanced Options page.

Add/Modify External Tool - Advanced Options

This page is used to specify advanced options for how the external tool will be executed.

Execution Actions

Execution Actions are used to specify one or more actions to be performed before and after your tool is executed. Use the Pre-Execution Actions tab to list the actions to be performed before execution, and the Post-Execution Actions tab to list the actions to be performed after execution. Select the proper tab and click the Add button to be prompted for an action to execute. The following actions are available:
Execution ActionDescription
Build ProjectThe Build process will be performed on the active project in Solution Explorer.
Build SolutionThe Build process will be performed on the open solution in Solution Explorer.
Download All ALM FilesAll ALM-based files from the open solution will be downloaded from the server and replace the local copies.
Warning:   All local files will be overwritten!
Download Modified ALM FilesAll ALM-based files from the open solution that have been modified on the server since the last download will be downloaded to the local machine.
Save Active ItemThe actively edited file or selected item in Solution Explorer will be saved. This option is useful if you need to ensure that any modifications are saved to disk before executing the tool on that file (since the tool will likely need to interact with the file on disk).
Save AllSaves all open files, projects, and solutions.
Save All EditorsSaves all open files only (projects and solutions are not saved).
Save ProjectSaves the active project in Solution Explorer.
Save SolutionSaves the open solution.
Upload All ALM FilesAll ALM-based files from the open solution will be uploaded from the local machine and replace the copies on the server.
Warning:   All server files will be overwritten!
Upload Modified ALM FilesAll ALM-based files from the open solution that have been modified on the local machine since last uploaded will be uploaded to the server.
Copy Selected Text to ClipboardThis action is valid for text-based editors that support the concept of "active text". When text is selected, the selected text will be copied to the clipboard. Otherwise, the most applicable text will be copied based on the position of the caret in the editor.

Actions are executed in the order they are displayed. Use the Move Up and Move Down buttons to change the order of the actions. The Remove button may be used to remove an action from the list.

Output

Command-line based applications typically display their output in a Command Prompt window. For convenience, you may check the Show in Output Window to have the output of your application redirected and displayed within the Test Design Studio Output Window.

Warning:   This feature should not be used on Windows-based applications or those that require user-input during execution.

When your selection is complete, click the Next button to proceed to the next page. If you selected the Add a new external tool option from the Welcome page, the next page displayed will be the final page. If you selected the View or change existing external tools option from the Welcome page, the next page displayed will be the View External Tools page.

View External Tools

This page is used to fully manage the available external tools. The grid displays all currently configured tools with details about each tool. Select any tool and select one of the following options:
ButtonDescription
Change...Edits the specified external tool. The Add/Modify External Tool - Tool Group page will be displayed for the selected tool.
Add...Adds a new external tool. The Add/Modify External Tool - Tool Group page will be displayed allowing you to create a new external tool.
RemoveRemoves the selected external tool
Move UpExternal tools are displayed in the Tools menu based on the order they are displayed. Select this option to move the selected external tool higher in the display order.
Move DownExternal tools are displayed in the Tools menu based on the order they are displayed. Select this option to move the selected external tool lower in the display order.
Click the Finish button when all changes have been made.

External Tool Groups

Add/Modify External Tool Group

This page is used to set the title of an external tool group. The title is displayed in the menu system for the sub-menu that is created to hold the external tools within this group. When your entry is complete, click the Next button to proceed to the next page. If you selected the Add a new external tool group option from the Welcome page, the next page displayed will be the final page. If you selected the View or change existing external tool groups option from the Welcome page, the next page displayed will be the View External Tool Groups page.

View External Tool Groups

This page is used to fully manage the available external tool groups. The grid displays all currently configured tool groups with details about each group. Select any tool group and select one of the following options:
ButtonDescription
Change...Edits the specified external tool group. The Add/Modify External Tool Group page will be displayed for the selected tool group.
Add...Adds a new external tool group. The Add/Modify External Tool Group page will be displayed allowing you to create a new external tool group.
RemoveRemoves the selected external tool group. Any groups previous assigned to this group will no longer be associated with a tool group.
Move UpExternal tool groups are displayed in the Tools menu based on the order they are displayed. Select this option to move the selected external tool group higher in the display order.
Move DownExternal tool groups are displayed in the Tools menu based on the order they are displayed. Select this option to move the selected external tool group lower in the display order.
Click the Finish button when all changes have been made.