Applies to TestComplete 14.30, last modified on November 21, 2019

The Tested Applications collection can include applications with the RunAs run mode, that is, configured to run under a specific user account. See Testing Applications Running Under Another User Account.

You can view and change application parameters, such as the application path and the user account, in the TestedApps editor. The parameters are organized into two sections - Basic Parameters and Run-Mode Parameters.

Basic Parameters

Basic parameters include the following:

Parameter Description
Name The unique name of the tested application in the Tested Applications collection. This name is used to refer to the application in tests, for example, in the Run TestedApp keyword test operation.
Run Mode The mode in which TestComplete will launch the application:
  • Simple - The application will be launched using the command-line and the working folder specified in the Run-Mode Parameters section, under the same user account that TestComplete is running under. This is similar to how a user would launch the application directly via its executable or using the Start menu or desktop shortcut.

  • RunAs - The application will be launched under a specific user account. See Testing Applications Running Under Another User Account.

  • Debug - Similar to the Simple mode, but TestComplete additionally traces and logs all exceptions and events (debug strings, module loading and so on) that occur in the application’s process. See Tracing Events and Exceptions With Debug Services.

  • Profile - The application will be launched under the AQtime profiler. AQtime will analyze the application performance, memory leaks, resource usage or other characteristics. In other words, the application will be tested by TestComplete and profiled by AQtime at the same time. See Integration With AQtime for more information.

Count The number of application instances that will be simultaneously launched during the test recording or run.
Autorun application on recording Select this option to have the application launched automatically when you start test recording.
Launch application from tests Uncheck this option to prevent the application from being launched by the Run TestedApp keyword test operation and the TestedApps.AppName.Run scripting method.

For example, you can define several instances of the tested application with different configurations and “disable” those not needed at the moment.

Run-Mode Parameters

The following parameters are specific to tested applications with the RunAs run mode:

Parameter Description
Application The name and path of the application executable file (.exe, .com, .bat or .cmd). You can enter the path manually or click the button and browse for the needed file.

The path can be fully-qualified or relative to the project folder. To switch between the fully-qualified and relative path representations, click the drop-down button and select the desired path in the drop-down list.

You can use environment variables, such as %PROGRAMFILES%, as well as project and project suite variables in the format $(VarName) in the file path. For more information, see Using Variables in Tested Application Paths.

If the application resides in a folder that is in the PATH environment variable, you can omit the application path and specify the file name only. For example, you can specify notepad.exe instead of C:\Windows\notepad.exe.

Note: The application path can be different on different computers. If you move the test project to other computers, the specified path may point to a non-existing location on those computers. To avoid the problem, it is recommended to install the application to a folder that is common to all test computers. You can also use environment, project or project suite variables in place of computer-specific path components. See Avoiding Computer-Specific Settings for more information.
User name The user account to launch the application under. This account must have a non-empty password.
Domain The name of the domain or computer to which the account belongs.
Password The password of the specified user account. The password characters are masked by dots for security purposes. The password is stored securely in one of the project files and encrypted using RC4 algorithm.
Command-line parameters The command-line arguments to be passed to the application.
Working folder The working folder for the application run. You can enter the folder path manually or click the button and browse for the needed folder.

The folder path can include environment variables, such as %PROGRAMFILES%, as well as project and project suite variables in the format $(VarName). For more information, see Using Variables in Tested Application Paths.

Important Notes

  • Using the RunAs run mode requires that the Secondary Logon service be running in Windows.

  • In order for TestComplete to be able to test an application launched under another user account, TestComplete must be running with administrator privileges. See also Using TestComplete With Administrator Privileges.

  • In order for TestComplete to have access to native properties and methods of application objects, the account under which TestComplete is running must have Default Access Permissions on the current computer. For more information, see Settings for Testing Open Applications in RunAs Mode.

See Also

Testing Applications Running Under Another User Account
About Tested Applications
About TestedApps Editor
Run Modes and Parameters
Using Variables in Tested Application Paths
Working With Tested Applications in Tests

Highlight search results