Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

eCATT: Dynamic <target system> for pattern REF possible?

Former Member
0 Likes
377

Hello

I am using eCATT on a Solution Manager (NetWeaver 700). I have to run the test scripts on several different SAP systems.

Therefore, I would like to know whether it is possible to set the target system within the pattern <b>REF </b>(<i>executes another eCATT test script, either on local or remote system</i>) <b><i>dynamically</i></b>?

Definite proof that this is <b>not </b>possible is also welcome.

I am aware that I can replace the REF pattern by a corresponding ABAP...ENDABAP coding, e.g.:

FUN ( BAPI_USER_EXISTENCE_CHECK , BAPI_USER_EXISTENCE_CHECK_1, <target_system> ).

Replace by:

ld_rfcdest = id_rfcdest.
ABAP.
  CLEAR: ls_return.

  CALL FUNCTION 'BAPI_USER_EXISTENCE_CHECK'
    DESTINATION ld_rfcdest
    EXPORTING
      username = id_username
    IMPORTING
      return      = ls_return.
" NOTE: Not necessary to handle RFC exceptions -> done by eCATT framework
ENDABAP.

" evaluate ls_return...

However, I would prefer - if possible - to use the REF pattern.

Regards,

Uwe

Hello

I am using eCATT on a Solution Manager (NetWeaver 700). I have to run the test scripts on several different SAP systems.

Therefore, I would like to know whether it is possible to set the target system within the pattern <b>REF </b>(<i>executes another eCATT test script, either on local or remote system</i>) <b><i>dynamically</i></b>?

Definite proof that this is <b>not </b>possible is also welcome.

I am aware that I can replace the REF pattern by a corresponding ABAP...ENDABAP coding, e.g.:

FUN ( BAPI_USER_EXISTENCE_CHECK , BAPI_USER_EXISTENCE_CHECK_1, <target_system> ).

Replace by:

ld_rfcdest = id_rfcdest.
ABAP.
  CLEAR: ls_return.

  CALL FUNCTION 'BAPI_USER_EXISTENCE_CHECK'
    DESTINATION ld_rfcdest
    EXPORTING
      username = id_username
    IMPORTING
      return      = ls_return.
" NOTE: Not necessary to handle RFC exceptions -> done by eCATT framework
ENDABAP.

" evaluate ls_return...

However, I would prefer - if possible - to use the REF pattern.

Regards,

Uwe

1 REPLY 1
Read only

uwe_schieferstein
Active Contributor
0 Likes
320

Hello

In case you may need this functionality here is (one possible) solution.

The testscript <b>ZUS_SDN_ECATT_DYNAMIC_TARGET</b> calls testscript ZUS_SDN_LOGICAL_SYSTEM_GET dynamically on different target systems.

Testscript ZUS_SDN_ECATT_DYNAMIC_TARGET:


*ECSC	Test Script
*ECTD	Test Data Container
*ECSD	System Data Container
*ECTC	Test Configuration

ls_execute = is_execute.
ABAP.
  APPEND ls_execute TO lt_execute.
ENDABAP.
et_execute = lt_execute.

FUN ( ECATT_EXECUTE , ECATT_EXECUTE_1 ).
CHEVAR( &EXCEPTION = ' ' ).
EXIT( &EXCEPTION <> ' ' ).

**FUN ( ECATT_LOG_DISPLAY , ECATT_LOG_DISPLAY_1 ).

The funny part of this script is the <b>FUN </b>pattern where I call function module <b>ECATT_EXECUTE</b> which is used to execute testscripts (or test configurations). As IMPORTING parameter we have a structure <b>START_PROFIL </b>where we can set the <b>SYSTEMDATA</b> (container) and the <b>TARGETSYSTEM</b>.

Hopefully I will find the time to explain this testscript and its possible use and implications in more detail in a blog.

Regards,

Uwe