Testing a Custom Control Using Automation Support

Before you can test a custom control in Silk Test Classic, perform the following steps:

  • Define the custom control in the test application.
  • Implement automation support.

You can create specific automation support for the custom control. This additional automation support provides recording support and more powerful play-back support. To create automation support, the test application must be modified and the Open Agent must be extended.

After the test application has been modified and includes automation support, perform the following steps:

  1. Open an existing Flex project or create a new project.
  2. Click File > New. The New File dialog box opens.
  3. Choose 4Test include and then click OK. A new include file opens.
  4. Type the custom control class information in the INC file and then click Save.
    For example, the INC file for the FlexSpinner class looks like the following:
    winclass FlexSpinner : FlexBox
      tag "[FlexSpinner]"
      builtin void Increment(INTEGER steps)
      builtin void Decrement(INTEGER steps)
      property stepSize
        builtin INTEGER Get()
      property lowerBound
        builtin INTEGER Get()
      property currentValue
        builtin INTEGER Get()
        builtin Set(INTEGER value)
      property upperBound
        builtin INTEGER Get()
  5. Click Options > Runtime Options and in the Use Files field navigate to the custom control INC file.
  6. Record and replay tests for the custom control.