Understanding the Contents of the Test Object Configuration File

A test object configuration file can include the following:

  • The name of the test object class and its attributes.

  • The name of the custom control for which this test object class definition is relevant.

  • The methods for the test object class, including the following information for each method:

    • The arguments, including the argument type and direction.

    • Whether the argument is mandatory, and, if not, its default value.

    • The description (shown as a tooltip in the Keyword View, Editor, and Step Generator).

    • The documentation string (shown in the Documentation column of the Keyword View and in the Step Generator).

    • A context-sensitive Help topic to open when F1 is pressed for the test object method in the Keyword View or Editor, or when the Operation Help button is clicked for the method in the Step Generator. The definition includes the Help file path and the relevant Help ID within the file. (Relevant only for new test object methods added to the test object class.)

    • The return value type.

  • The test object method that is selected by default in the Keyword View and Step Generator when a step is generated for a test object of this class.

The following example shows parts of the SwfObject test object class definition in a test object configuration file. The example shows that the SwfObject is extended by adding a MyCustomButtonSet method. The method has one argument (Percent, which defines the percentage to set in the control), and it also has a documentation string that appears in the Keyword View:

</TypeInformation>
...
    <ClassInfo BaseClassInfoName="SwfObject" Name="MyCompany.MyButton">
...
        <TypeInfo>
            <Operation Name="MyCustomButtonSet"PropertyType="Method" ExposureLevel="CommonUsed">
                  <Description>Set the percentage in the task bar</Description>
                  <Documentation><![CDATA[Set the %l %t to <Percent> percent.]]></Documentation>
                    <Argument Name="Percent" IsMandatory="true" Direction="In">
                        <Type VariantType="Integer"/>
                        <Description>The percentage to set in the task bar.</Description>
                    </Argument>
            </Operation>
        </TypeInfo>
    </ClassInfo>
</TypeInformation>

For information on the structure and syntax of a test object configuration file, see the UFT One Test Object Schema Help