Top Banner
OATS An Alternative to SOAPUI Anurag Deb HUB4TECHIE.COM
16

Open Script (OATS)

Jan 28, 2018

Download

Software

Anurag Deb
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Open Script (OATS)

OATS

An Alternative to SOAPUI

Anurag Deb HUB4TECHIE.COM

Page 2: Open Script (OATS)

1 Introduction Here we have quick tutorial about how to use OATS as alternative to SOAP UI.

1.1 Start OpenScript Application

Open your directory where you installed open script l ike (D:\OpenScript\openScript\OpenScript.exe).

Page 3: Open Script (OATS)

2 Functional testing through OATS Tool. 2.1 Creating Script

1. We will now create the web services

Go to File -> New -> General -> Web Services

2. Select the samples workspace -> name it and click Finish

“Treeapi” script is ready with 3 methods Initialize, Run, Finish

treeapi

Page 4: Open Script (OATS)

3. Open WSDL Manager and click add wsdl file.

4. Select your wsdl file.

5. Click next and check the requests available in your wsdl file if you want. Then click Finish

Page 5: Open Script (OATS)

6. Uploaded Wsdl file appears in the WSDL Manager window.

7. Follow below steps to Add the wsdl file to the script “treeapi” you created .

8. Click on the Run button to expand.

All the requests will be listed.

1. Click on wsdl file which you added.

2. Right click and Add to script.

3. It will be added under Run method

Page 6: Open Script (OATS)

9. Click on any request to expand further, in this case clicking on “Create” request.

10. Change your endpoint.

Click here to open “Ws Post Navigation” Window. Edit the URL(Endpoint)

Page 7: Open Script (OATS)

11. To view Details Click on View > Details.

12. Click on XML Post data to edit the request like provisioning the data.

13. To view it in readable format Right click on “Details” Tab and Click on “Format”.

Page 8: Open Script (OATS)

14. Now if you want to execute just the first request then skip the remaining requests as below . Else other requests which might not have been corrected/provisioned will also get executed.

This whole Run method implements If loop.

Requests which are skipped comes under if(false) condition.

In this example we will be running only “getECNTree”

request.

Page 9: Open Script (OATS)

15. To Execute we have two options.

16. After executing we can check the response as below

1. Playback

2. Iterate

Detailed Response

Also clicking here will open the result

Page 10: Open Script (OATS)

3 Load Testing For load we need bulk inputs so we have options:

1) Csv file 2) Database

3.1 How to Add Databank for bulk execution

1. Click on endpoint and select “Get Database Record”.

2. Which record you want the tool to take.

Record means row of input in your excel(csv) sheet/database.

Save your excel in csv format.

Page 11: Open Script (OATS)

3. Select CSV or Database Databank

4. In this example we have selected CSV databank. Now select your csv file.

5. After that Databank will be added to your request.

Now we will substitute values with real values from excel.

Select the value to replace like here I want to substitute treename value from excel.

In this example selecting treename value and right click and select “Substitute variable” option.

Databank added here.

Tree is the name of file 2 represents the no. of rows

present in csv file. Select value

of the tag

Page 12: Open Script (OATS)

6. You can create new databank or use the existing(created in above steps).

7. Choosing a new databank. Click “Add new Databank” option as in Step 6.

Choose “CSV File” option.

Create new Databank

Existing one which we created in

above steps

Page 13: Open Script (OATS)

8. Selecting csv file “tree.csv” and name an alias.

9. Clicking Next button will give you the rows present in the csv file.

Click Finish .

Mapping

with the excel

Page 14: Open Script (OATS)

10. Going back to Step 5(substitute variable)

11. Substitute Variable Dialogue will appear.

12. Original value will be replaced by substituted value.

Select tag value (site2 in my case)

and right click and click “Substitute

Variable” option.

Select column

containing the

value

Original value Site2

changed to

Page 15: Open Script (OATS)

For results

Page 16: Open Script (OATS)