Contents of a Compiled Module - WinRunner

A compiled module, like a regular test you create in TSL, can be opened, edited, and saved. You indicate that a test is a compiled module in the General tab of the Test Properties dialog box, by selecting Compiled Module in the Test Type box. For more information, see “Creating a Compiled Module”

The content of a compiled module differs from that of an ordinary test: it cannot include checkpoints or any analog input such as mouse tracking. The purpose of a compiled module is not to perform a test, but to store functions you use most frequently so that they can be quickly and conveniently accessed from other tests.

Unlike an ordinary test, all data objects (variables, constants, arrays) in a compiled module must be declared before use. The structure of a compiled module is similar to a C program file, in that it may contain the following elements:

  • function definitions and declarations for variables, constants and arrays. For more information, see “Creating User-Defined Functions.”
  • prototypes of external functions. For more information, see “Calling Functions from External Libraries.”
  • load statements to other modules. For more information, see “Loading and Unloading a Compiled Module”
  • Note that when user-defined functions appear in compiled modules:

  • A public function is available to all modules and tests, while a static function is available only to the module within which it was defined.
  • The loaded module remains resident in memory even when test execution is aborted. However, all variables defined within the module (whether static or public) are initialized.

All rights reserved © 2018 Wisdom IT Services India Pvt. Ltd Protection Status

WinRunner Topics