Tutorial: Learning to Create Java Custom Toolkit Support > Learning to Support a Simple Control > Deploying and Testing the New Custom Toolkit Support

Deploying and Testing the New Custom Toolkit Support

In this part of the lesson, you use the UFTDeploy Toolkit Support command in Eclipse to deploy the ImageControls toolkit support to UFT. Currently only one control in this toolkit, the ImageButton control, is supported. The toolkit support is not yet complete, but you can already test the support created up to this point.

  1. Deploy the ImageControls toolkit support to UFT.

    In the Eclipse Package Explorer tab, select the ImageControlsSupport project.

    Click the Deploy Toolkit Support button, or select UFT > Deploy Toolkit Support. In the confirmation messages that open, click Yes and then OK.

    The toolkit configuration file and the test object configuration file are copied to the relevant folders in your UFT installation folder. The custom support will be available the next time you open UFT and start the custom application.

    For more information on deploying custom toolkit support, see Deploying and Running the Custom Toolkit Support.

  2. Open UFT and load the Java Add-in and the custom toolkit support.

    Open UFT. The Add-in Manager dialog box displays ImageControls as a child of the Java Add-in in the list of available add-ins. (If the Add-in Manager dialog box does not open, see the Micro Focus Unified Functional Testing Add-ins Guide for instructions.)

    Select the check box for ImageControls and click OK. UFT opens and loads the support you designed.

  3. Run the SampleApp application.

    UFT establishes its connection with an application when the application opens. Therefore, if the SampleApp application is open, you must close and re-run it.

    In the Eclipse Package Explorer tab, right-click SampleApp. Select Run As > Java Application. The SampleApp application opens.

  4. Test the new custom support.

    View the ImageButton control with the UFT Object Spy and try to record a Click operation on it. For details, see the steps in Planning Support for the ImageButton Control.

    • UFT recognizes the ImageButton as a JavaButton named ImageButton.

    • The new support class (ImageButtonCS) inherited some identification properties from the base support class (CanvasCS) that are not included in the JavaButton test object class definition. These properties are displayed in the Custom Support Test Object Identification Properties screen, but they are not displayed in UFT in the Object Spy or in the Checkpoint Properties dialog box. You can access these identification properties by using the GetROProperty method. For more information on the GetROProperty method, see the Micro Focus UFT Object Model Reference for GUI Testing.

    • Because you have overridden the low-level recording, but have not yet implemented the actionPerformed(ActionEvent arg0) event handler method, UFT currently does not record anything when you click the button.