Test and debug your test object operation support

This task describes how to run your test object operations from within Extensibility Accelerator, so that you can test and debug your JavaScript implementation functions.

Note: This task is part of a higher-level task. For details, see Design test object class operations .

Prerequisites

  1. If you are running on Microsoft Internet Explorer, enable script debugging in Microsoft Internet Explorer.

    For example: In Internet Explorer 7.0, select Tools > Internet Options. In the Advanced tab, clear the Disable Script Debugging options in the Browsing group.

    Extensibility Accelerator 2022 or later:  If you are running on Google Chrome, press F12 to open DevTools and use it to debug your functions.

  2. Open the application on which you want to run and debug your operation, and make sure that the page is fully loaded and the relevant control is visible. (You must run Extensibility Accelerator and open a project before you open the web browser.)

  3. Make sure that the rules displayed in the rule editor for your test object class correctly identify the control on which you want to debug the operation.

    You can click Test All Rules in the Map to Controls tab (Test Object Class designer) and verify that the control is highlighted in the application.

Back to top

Set a breakpoint in your implementation function - Optional

If you want the run session to pause when it reaches the function that you designed to support the operation, you can add a breakpoint at the beginning of the function.

If you are using Internet Explorer, use the Microsoft Visual Studio JavaScript debugging tools available in Extensibility Accelerator to add the breakpoint.

If you are using Google Chrome, use the DevTools capabilities.

Back to top

Select the operation to run

In the Debug Test Object Operation dialog box, select the test object class operation to run:

  1. Do one of the following:

    • In the Class View, right-click the operation and select Debug. The Debug Test Object Operation dialog box opens with the test object class and operation selected.

    • In theOperations tab (Test Object Class designer), select an operation from the operation list and click the Debug Operation button in the operation list toolbar. The Debug Test Object Operation dialog box opens with the test object class and operation selected.

    • Select Project > Debug Test Object Operation. In the Debug Test Object Operation dialog box that opens, select the test object class and the operation that you want to run.

  2. If the operation you selected receives arguments, a table displays the argument names, whether they are optional, and the type of value they require. If necessary, enter the argument values to pass to the operation.

Back to top

Select an application control on which to run the operation

  1. In the Debug Test Object Operation dialog box, click Select Control. Extensibility Accelerator is hidden, all of the controls that match the mapping rules in all open Web applications, are highlighted, and a Cancel button is displayed at the top of the screen.

    In many cases you can open or navigate to additional applications or Web pages at this point. Once the application or page loads successfully, the matching controls are highlighted in it as well. (To navigate at this point, you need to hold down the Ctrl key.)

    If a specific page does not load properly when navigating to it at this point, load that page in an additional browser before clicking Select Control.

    Note: Controls are highlighted only in browsers that are opened after you open a project in Extensibility Accelerator.

  2. Click the control on which you want to run the operation. You must select one of the highlighted controls.

    The highlighting is removed from the application, Extensibility Accelerator opens and the Debug Test Object Operation dialog box is displayed.

Back to top

Run the operation

In the Debug Test Object Operation dialog box, click Run Operation. Extensibility Accelerator begins to run the test object operation on the control you selected, calling the operation's JavaScript implementation function.

If you ran the operation on a control running in Microsoft Internet Explorer, you can now debug your functions using the Microsoft Visual Studio Shell debugging tools that are available in Extensibility Accelerator.

If you ran the operation on a control running in Google Chrome, use the DevTools capabilities to debug it.

Back to top