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

Former Member
0 Likes
837

hi,

how to upload data in ecatt

6 REPLIES 6
Read only

Former Member
0 Likes
783

check these link,

eCATT- An Introduction

/people/sumeet.kaul/blog/2005/07/26/ecatt-an-introduction

Creating Test Scripts

/people/sumeet.kaul/blog/2005/08/10/ecatt-creating-test-scripts

eCATT Logs

/people/sapna.modi/blog/2006/04/18/ecatt-logs-part-vi

eCATT Scripts Creation – TCD Mode

/people/sapna.modi/blog/2006/04/10/ecatt-scripts-creation-150-tcd-mode-part-ii

Creation of Test Data Container

/people/sumeet.kaul/blog/2005/08/24/ecatt-creation-of-test-data-container

eCATT Scripts Creation - SAPGUI Mode

/people/sapna.modi/blog/2006/04/10/ecatt-scripts-creation--sapgui-mode-part-iii

Integrating ECATT & MERCURY QTP Part -1

/people/community.user/blog/2007/01/02/integrating-ecatt-mercury-qtp-part-1

Using eCatt to Test Web Dynpro ABAP

/people/thomas.jung/blog/2006/03/21/using-ecatt-to-test-web-dynpro-abap

and

-command reference

http://help.sap.com/saphelp_nw04/helpdata/en/c6/3c333b40389c46e10000000a114084/content.htm

/people/sapna.modi/blog/2006/04/10/ecatt--an-introduction-part-i

http://prasadbabu.blogspot.com

https://www.sdn.sap.com/sdn/developerareas/was.sdn?page=test_tool_integration_for_sap_e-catt.htm

http://help.sap.com/saphelp_nw04/helpdata/en/1b/e81c3b84e65e7be10000000a11402f/frameset.htm

http://www.erpgenie.com/ecatt/index.htm

hope this helps.

Reward points if useful.

Read only

Former Member
0 Likes
783

Hi,,

Supriya..

1. On the Extended Computer Aided Test Tool: Initial Screen, choose eCATT Object ® Upload.

A dialog box appears.

2. Choose the folder where the files are located.

3. Select the file or files, then choose Open.

A dialog box appears.

4. In the relevant Target object field, enter a name for the eCATT object.

5. If the eCATT object is a test script, you can enter a version number in the Target Version field.

6. Choose Tick .

If any of the RFC destinations do not exist in the system, the Status field will be marked yellow. However, that does not prevent the upload.

7. Choose Tick.

plzz reward if itis useful....

Read only

Former Member
0 Likes
783

Hi

Try this, may be it will help you.

Reward if help.

Extended Computer Aided Test Tool (eCATT) to create and execute functional tests for software. The primary aim is the automatic testing of SAP business processes. Each test generates a detailed log that documents the test process and results.

Features

You can:

· Test transactions and reports

· Call BAPIs and function modules

· Test remote systems

· Check authorizations (user profiles)

· Test database updates

· Test the effects of changes to customizing tables

· Test the effect of changes to customizing settings

· Check system messages

Constraints

eCATT runs in a system based on SAP Web Application Server 6.20 or higher. However, you can use this system to test systems with Release 4.6C or higher.

check these link,

eCATT- An Introduction

/people/sumeet.kaul/blog/2005/07/26/ecatt-an-introduction

Creating Test Scripts

/people/sumeet.kaul/blog/2005/08/10/ecatt-creating-test-scripts

eCATT Logs

/people/sapna.modi/blog/2006/04/18/ecatt-logs-part-vi

eCATT Scripts Creation – TCD Mode

/people/sapna.modi/blog/2006/04/10/ecatt-scripts-creation-150-tcd-mode-part-ii

Creation of Test Data Container

/people/sumeet.kaul/blog/2005/08/24/ecatt-creation-of-test-data-container

eCATT Scripts Creation - SAPGUI Mode

/people/sapna.modi/blog/2006/04/10/ecatt-scripts-creation--sapgui-mode-part-iii

Integrating ECATT & MERCURY QTP Part -1

/people/community.user/blog/2007/01/02/integrating-ecatt-mercury-qtp-part-1

Using eCatt to Test Web Dynpro ABAP

/people/thomas.jung/blog/2006/03/21/using-ecatt-to-test-web-dynpro-abap

and

-command reference

http://help.sap.com/saphelp_nw04/helpdata/en/c6/3c333b40389c46e10000000a114084/content.htm

/people/sapna.modi/blog/2006/04/10/ecatt--an-introduction-part-i

http://prasadbabu.blogspot.com

https://www.sdn.sap.com/sdn/developerareas/was.sdn?page=test_tool_integration_for_sap_e-catt.htm

http://help.sap.com/saphelp_nw04/helpdata/en/1b/e81c3b84e65e7be10000000a11402f/frameset.htm

http://www.erpgenie.com/ecatt/index.htm

hope this helps.

Read only

Former Member
0 Likes
783

if u cannot see the screen shots here please visit

http://www.sapdevelopment.co.uk/testing/ecatt.htm

Loading test data from a file in 4.7X with example:

We can load test data from file using the ABAP…ENDABAP [18] statements in eCATT.

In this article I have given an example on transaction code MM01 with sample code.

To upload the test data file follow the steps given,

Record the transaction

Open eCATT tool. This can be done using ‘SECATT’ tcode.

Give the script name and version number example ‘ZTS_MM01’.

Version number can be used to maintain different program constructs under same program name. And choose create button.

Give description and component name as ‘BC-TWB-TST-ECA’.

Select editor tab panel. Then click on ‘pattern’ button. Or go to Edit->Pattern or Press Ctrl+F6. This opens a ‘insert statement’ dialog box.

In that command dropdown box choose TDC (Record) option. Then press enter.

Enter the transaction name as ‘mm01’ then MM01_1 interface automatically created. Then press enter.

Then ‘Create Material: Initial screen’ will appear. Enter the necessary fields.

And be careful while recording, if not recording may fail. Note that while recording no error messages should pop up. If they happen restart the recording process. Here in this example I have considered a simple recording process. You can do any complex recording. If you have any doubts do feel free to mail me. I will reply to you.

After completing the recording process recording ended dialog will appear.

Choose ‘Yes’.

Then a TCD statement will appear in the editor area.

With this we have finished recording

Now let us see the variable declaration, assignment and programming part.

After developing as number of scripts I found one simple method to develop these test scripts. If you feel comfortable with this method you can also use it.

First note down the all screen fields in which you are entering values during recording process. Then create local variables in eCATT with the same name as the screen field technical name. (This method makes assignment easier).

Example:

In MM01 (material master) I have entered values for material, industry sector and material type. And their respective technical screen field values are,

RMMG1-MATNR

RMMG1-MBRSH

RMMG1-MTART

To find out technical value of the screen field select the field press F1, then clicks on technical information button.

And now create the local variable as

V_MATNR,

V_MBRSH,

V_MTART,

To create local variables first click button, and then to create new variable click button. And enter the variable name [19] as (V_MATNR), Visibility of parameter [110] as ‘V’ and finally parameter reference [111] (name of the actual parameter). After declaring all the parameter it will look like this,

After declaring the local variables we need to assign them to screen field values.

To do that again press or double click on MM01_1 in TCD (MM01, MM01_1) statement. This will take you to the command interface which look like,

To assign the screen field values double click on the ‘FIELD’.

Then replace the screen VALIN[112] values with the local variable names. After changing the values the interface look like this,

Repeat the above step with all the screen field values. With this we have finished the process of declaring and assigning variables.

Now we will see how to program and run the script successfully.

To write the program we need to follow two steps. They are,

Get the number (count) of records in file.

Loop through count number of times and load the data from the file pass to TCD through local variables of eCATT.

Let us see how to handle the things,

By using ABAP…ENDABAP statements we can do that.

Before we start writing the program we need to declare some local variables (to run he example program given) which help us to store values between two ABAP blocks.

Because in eCATT each ABAP…ENDABAP block creates different internal function module with different contexts. So we need to declare some intermediate variables they are,

COUNT[113] : Holds the number of records.

FILE_V[114] : Holds file path of the test data file.

INT_LOC[115] : Index to read next from the file.

I am giving sample code to get the number of records from file in eCATT. Use this code and try for MM01 for Basic view. It will work fine.

This is very simple ABAP code. For understanding purpose necessary comments are provided.

Step 1:

First ABAP…ENDABAP block, to get the number of records from the file and store the value in the COUNT local variable.

  • ABAP BLOCK TO GET THE NUMBER OF TEST CASES

ABAP.[116]

  • TOT : holds total number of records

  • FILE: holds file path of test file

DATA : TOT TYPE I VALUE 0,

FILE TYPE STRING.

  • ITAB TO HOLD TEST DATA FROM FILE

DATA : BEGIN OF I_MARA [117] OCCURS 0,

V_MATNR LIKE RMMG1-MATNR, " Material Number

V_MBRSH LIKE RMMG1-MBRSH, " Industry Sector

V_MTART LIKE RMMG1-MTART, " Material Type

  • Basic View

V_MAKTX LIKE MAKT-MAKTX, " Material Description

V_MEINS LIKE MARA-MEINS, " Basic Unit of Measure

END OF I_MARA.

  • TO OPEN FILE DIALOG FOR TEST DATA FILE

CALL FUNCTION 'F4_FILENAME[118] '

EXPORTING

PROGRAM_NAME = SYST-CPROG

DYNPRO_NUMBER = SYST-DYNNR

FIELD_NAME = 'FILE'

IMPORTING

FILE_NAME = FILE_V-PATH.

FILE = FILE_V-PATH.

  • LOADING DATA FROM THE FILE

CALL FUNCTION 'GUI_UPLOAD[119] '

EXPORTING

FILENAME = FILE

HAS_FIELD_SEPARATOR = 'X'

TABLES

DATA_TAB = I_MARA.

  • GETTING NUMBER OF RECORDS IN THE TABLE

DESCRIBE TABLE I_MARA LINES TOT.

  • STORING NUMBER OF RECORDS IN LOCAL VARIABLE

COUNT = TOT.[120]

  • CLEARING INTERNAL TABLE

CLEAR I_MARA.

ENDABAP.

Step 2:

Looping through the records count number of times and reading from the internal table and passing them to the screen field values.

This sample code explains how to read, and pass values to the screen.

  • LOOPING THROUGH (COUNT) NUMBER OF RECORDS

DO (COUNT[121] ).

ABAP.

  • V_READINDX : holds index number to read the internal table

  • FILE: holds file path of test file

DATA : V_READINDX TYPE I,

FILE TYPE STRING,

INDX TYPE I VALUE 0.

  • ITAB TO HOLD TEST DATA FROM FILE

DATA : BEGIN OF I_MARA OCCURS 0,

V_MATNR LIKE RMMG1-MATNR, " Material Number

V_MBRSH LIKE RMMG1-MBRSH, " Industry Sector

V_MTART LIKE RMMG1-MTART, " Material Type

V_MAKTX LIKE MAKT-MAKTX, " Material Description

V_MEINS LIKE MARA-MEINS, " Basic Unit of Measure

END OF I_MARA.

  • WORKAREA TO HOLD THE I_MARA DATA

DATA : WA LIKE I_MARA.

FILE = FILE_V-PATH.

  • LOADING MASTER DATA FROM THE FILE

CALL FUNCTION 'GUI_UPLOAD'

EXPORTING

FILENAME = FILE

HAS_FIELD_SEPARATOR = 'X'

TABLES

DATA_TAB = I_MARA.

  • INT_LOC : is a local variable hold the current index to read I_MARA

V_READINDX = INT_LOC.

  • READING I_MARA UGING ITS INDEX

READ TABLE I_MARA INDEX V_READINDX INTO WA.

  • assigning work area values to the screen field values

V_MATNR = WA-V_MATNR. " Material Number

V_MBRSH = WA-V_MBRSH. " Industry Sector

V_MTART = WA-V_MTART. " Material Type

V_MAKTX = WA-V_MAKTX. " Material Description

V_MEINS = WA-V_MEINS. " Basic Unit of Measure

ENDABAP.

  • TCD Transaction /////////////////////

TCD ( MM01 , MM01_1 ).[122]

  • move index position by one

INT_LOC = INT_LOC + 1.

ENDDO.

Reward points if useful

Read only

Former Member
Read only

Former Member
0 Likes
783

Hi Supriya,

These are the steps Below

1 Recording a test case

1.1 To record a test case, call Transaction SCAT and enter test case ZVenduser_creat.

Do not choose Enter.

Choose Test Case → Record Transaction. Enter Transaction XK01, and choose Record/Enter.

The system runs Transaction XK01.

Enter the user name TESTZ and choose Create.

Enter the user’s title first name ZEBRA and the last name TEST.

Select the Logon data tab, enter init as the initial password, and repeat the password, profile select sap_all then choose Save.

Go back a screen and

In the dialog box displayed, select End recording.

A message is displayed stating that the recording has ended.

Enter the test case title User maintenance.

In the field Component, enter Vendor master component.

Save the test case.

In the field package class, enter $TMP.

Choose Save to save the attributes.

To save the test case functions, go back.

2 Entering parameters for a test case

2.1 To define parameters for a test case, call Transaction SCAT.

Enter the test case name ZVendor_creat.

Select Functions and choose Change.

Double-click on TCD.

Then double-click on program screen . (first appearance of this program)

The first screen of Transaction XK01 is displayed. (If you backed out, enter the procedure name again and double-click on TCD.)

Double-click on the user name field. In the field Param. name, enter an "&", and choose Copy/Enter.

Choose Next screen and double-click the last name. In the field Param. name, enter an "&" and choose Copy/Enter.

Go back until the Save folder appears, and choose Save.

3 Creating and using an external variant for the test case

3.1 To export the default parameters into a frontend file, in the test case, select Goto → Variants → Export Default.

Note: The default file name is <the name of your test case>.txt. Do not change the default values.

3.2 Open the file, with excel and edit and add another couple of user, and save the text file

3.3 To execute the test case using the external variant from file, from the initial CATT screen, enter the test case name and choose Execute.

In the field Variants, select External from file and choose Choose. Select the file created above, and choose Open. Under Processing mode, select Errors, and choose Execute.

Note: When you use this method, the file must be imported each time the test case is executed (file remains only on PC).

kindly reward if found helpful.

cheers,

Hema.