Show TOC

Procedure documentationCreating Screen Components for ABAP Web Dynpro Applications

 

When you need to manually edit a test, it can be necessary to generate screen components manually. This document describes this activity for a Web Dynpro ABAP application.

A screen component can be inserted as a step of a test script. Each parameter of a screen component corresponds to an input field, such as dropdown menu, check box, or radio button, in the automated user interface. At execution time, each parameter that is provided with a value is populated with this value in the corresponding user interface.

So it you can reuse screen components in several tests. This makes it easier to repair tests if systems are updated with new service packs or custom developments.

Note Note

You can only reuse screen components in tests that use the same logical component. This ensures that tested products have the same version. If no logical component is used in the target component of the system data container of the test, the product versions of the system under test are used to assemble compatible screen components.

Creating screen components manually is an advanced function. We recommend that you automatically record test scripts with CBTA recording wizard.

End of the note.

For ABAP Web Dynpro applications, the screen components are generated based on statically defined Web Dynpro views, from the same or a used component.

If a Web Dynpro view is generated dynamically at runtime, you cannot create a screen component. Use a default component instead. For more information, see the separate document on default components under Start of the navigation path http://wiki.scn.sap.com/wiki/x/kQ_IFQInformation published on SAP site Next navigation step Test Option 1 End of the navigation path.

Prerequisites

You have created a test script with an ABAP Web Dynpro executable object.

The ABAP Web Dynpro executable object includes the name of the application.

Procedure

  1. To identify the name of the relevant view, in the Web Dynpro application UI, choose Technical Help in the context menu of a field, and take note of the following:

    • Web Dynpro component displayed under Start of the navigation path Web Dynpro Application Next navigation step Start Component End of the navigation path

    • View name displayed under Views and View Elements

  2. In the Test Management work center, under Test Repository, open the test script or test configuration for editing.

    To inspect the relevant view, choose CBTA Inspection on the Test Script tab. The Inspection Wizard is started.

  3. Select the view and choose Next.

    The screen component is generated

  4. Choose Finish.

  5. Add the screen component, and the corresponding parameters, to the script.

  6. Identify the parameter value of the parent context URI (PARENTCONTEXTURI).

    Caution Caution

    • The PARENTCONTEXTURI parameter is specific to ABAP Web Dynpros. It is necessary for the usability of the screen component.

    • Use the Object Spy function to retrieve the identifier (URI) of a user interface control. Use it only in applications with stable IDs (parameter sap-wd-stableids = X must be set in the URL).

    End of the caution.
    1. Open the application that you want to test.

    2. Go back to the editor for test scripts. On the Test Script tab, under Parameters, choose Get Technical UI Information.

      You go to the Object Spy.

    3. On the Web Application tab page, select the session that you previously opened.

    4. Choose Spy.

    5. Position the cursor on a field in the Web Dynpro view. The field is highlighted red.

    6. To display the value of the PARENTCONTEXTURI parameter, in the Property Name tree go to Start of the navigation path Light Speed UI Next navigation step Light Speed Context Next navigation step Parent Context Uri End of the navigation path.

  7. Enter the value of the PARENTCONTEXTURI parameter in the parameters of the screen component.