How to use SAP eCATT with UiPath

In SAP development environments you can use the extended Computer Aided Test Tool (eCATT) to create and execute functional tests for software. You can find many detail information about eCATT in the SAP Help Portal. If you already have a bunch of eCATT test processes, it may be useful to link them with UiPath. On the one hand you can continue to use your consolidated eCATT test processes and on the other hand you can use the advantages of the different test automation tools.

To use SAP eCATT with UiPath is a little bit preparation necessary. In my post at the SAP Community I described how to use eCATT via HTTP request. On this way you get an interface to eCATT which you can easily use with UiPath web activity package.

Yes, the functional overlaps of eCATT and UiPath is present. You can both use for test automation scenarios in SAP context. But the combination of both is incredible.

Let us talk about a tiny scenario to show the possibilities: You can define an integrated test process in UiPath which uses native applications and SAP elements. And in the context of SAP you can use also eCATT, which offers the possibility to use inline ABAP. ABAP (Advanced Business Application Programming) is the SAP programming language. And with eCATT is it possible to execute your eCATT code on any SAP backend system in your landscape. Look at the interface of the HTTP request, in contains the target system. On this way you can collect data or customizing information from your whole SAP landscape easily and use this in your UiPath process.

Let me emphasize again that eCATT can not be used in productive environments, but only in test and development environments. For the purpose of test automation scenarios fantastic combination possibilities emerge.

The following images shows how to use an eCATT input parameter from UiPath in combination with inline ABAP.

Last but not least an eCATT script to read any SAP table and to deliver the content of this table to UiPath.



  TYPES: BEGIN OF ts_record,
           key TYPE string,
           value TYPE string,
         END OF ts_record.

    <lt_itab> TYPE ANY TABLE.

    lt_input  TYPE STANDARD TABLE OF ts_record,
    ls_input  TYPE ts_record,
    lv_table  TYPE tabname,
    lr_data   TYPE REF TO DATA.

      json = lv_input
      data = lt_input

  LOOP AT lt_input INTO ls_input.
    CASE ls_input-key.
      WHEN 'tablename'.
        lv_table = ls_input-value.

  CREATE DATA lr_data TYPE TABLE OF (lv_table).
  ASSIGN lr_data->* TO <lt_itab>.
  SELECT * FROM (lv_table) INTO TABLE <lt_itab>.

  lv_output = /ui2/cl_json=>serialize( data = <lt_itab> ).