Description

Avo Assure is a scriptless test automation tool for software and project testing implementations. This article provides the essential information and steps to integrate GenRocket with Avo Assure.


Note: Click here to access the Avo Assure documentation.


In This Article


Prerequisite Requirements

Access and installation of the following items: 

  • Avo Assure
  • GenRocket
  • GMUS


Web Application in Example

Using GMUS APIs, this example will generate the data for automating the GenRocket Bank application. This example shows the automation of the following for adding a user.

  1. Log into the Application
  2. Select Manage
  3. Select Users
  4. Add New User
  5. Enter User Information
  6. Save User Information


Scenarios in Test :

  • Positive Dataset: Add a new user with positive test data. 
  • Negative Dataset: Add a new user with negative test data, and an error message will be provided.







Step 1 - Setup GenRocket Multi-User Server (GMUS)

GenRocket Multi-User Server (GMUS) must be setup to complete Step 4a in this article. Complete the following to do so: 

  1. Add Client Application to GenRocket (Only Org Admins can do this)
  2. Register Client Application User with GenRocket
  3. Launch GMUS to Send Requests and Receive Responses

Note: To learn more, please see this article: GenRocket Multi-User Server (GMUS) Overview.


Step 2 - Setup a Project in the GenRocket Web Platform

Next, you must setup a Project within GenRocket to request the synthetic test data through Avo Assure. 


Step 2a - Basic Project Setup

For this example, a simple Project has been setup with one Domain titled 'UserData'. The steps for this Domain are as follows: 

  1. Create a Project (or a new Project Version)
  2. Create the Domain with its Attributes
  3. Add a Receiver to the Domain
  4. Create a Scenario for the Domain


As shown below, a single Domain has been created with several Attributes. The user has added the JSONFileReceiver for the output format and created a Scenario. 



Step 2b - Create One or More Cases

Cases make generating the variations and volumes of data you need easy. The basic steps are outlined below:

  1. Access G-Cases from the GenRocket Web Platform
  2. Create a New Suite and Add a Category
  3. Create One or More Cases (add Domains, alter loopCounts, modify Generators, etc.)


Note: Please see this article for more information: Test Data Cases (G-Cases) Overview.


Two cases have been set up for this example to generate positive and negative data sets. Cases make it easy to configure the data needed for each testing requirement. 



In the negativeDataSet case, four Generators have been linked and configured to generate a negative SSN for every four values. This configuration only applies to this case and no others. Below is a preview of the data that will be generated.



Step 3 - Store the API Request Values in a Data Table

Before creating the Projects, you must create a Data Table in Avo Assure to keep the variables that are part of the API Request parameterized.



Step 4 - Create API Project 

Click on Design to get started or create a new Project.



Step 4a - Create a Module, Scenario, Screen, and Test Case

You can find detailed steps in the Avo Assure documentation. The example shown below contains two flows: one for positive and one for negative test data. 



Step 4b - Capture Elements for the Screen (Request/Response)

For this step, the user will enter the API request information, which connects to the GMUS Server and receives a response. This step ensures Avo Assure can connect to the GMUS API and obtain test data from GenRocket.

  • Click on the Screen and select Capture Elements.

     
  • Enter the Request information (API URL, API Method, Request Header, and Request API Payload).


  • Click on Web Service to connect to the GMUS Server, which executes the GenRocket Scenario and provides a response that contains the generated test data. The 'inMemory' parameter in the API request is set to 'both'; hence, the data gets generated in the file format and in-memory.


Step 4c - Configure the Test Case

Next, you will need to design the test steps by using the parameters that have been set in the previous steps. Each parameter within the Request body is captured individually as a separate line.


Set the following WebService List items at the top: 

  • Line 3 setEndPointURL
  • Line 4 setHeader
  • Line 5 setMethods
  • Line 6 setWholeBody


The values are parameterized here and retrieved from the data table created in Step 1.



Once finished, set up all the parameters available in the request (Step 2b) so that those variables can also be parameterized. To set the value, select the setTagValue operation for each one. (see below) 



Line 19 executes the GenRocket GMUS API, and the API response is stored into a variable {APIResponse}.


To retrieve the generated data from the API response, select the getKeyValue operation and assign it to a variable [{title},{firstname}] to be used in the web automation test case.



Step 5 - Create Web Project

To create the web automation test case, use the Sample_Web and go to the design phase. Create the same flow as in Step 2, and the variables created in Step 2 to capture the data from API responses will be used here to enter the data in the forms.


 

For the Screen, capture all the elements that are required to operate and navigate for the automation. 



Then, for the Test Case Design Steps, capture and design how the workflow is supposed to be executed. 


Instead of hard-coded values, we can use the GenRocket generated data captured in the API Response and stored into the variables shown in Step 2.



Step 6 - Create End to End Project (API + Web Project)

The API Test Case (Step 2) and the Web Automation Test Case (Step 3) need to be combined into an End to End Project (shown below). To add an item to the flow: 

  1. Create a New End to End flow
  2. Select a Module
  3. Select a Scenario
  4. Click Add


In this flow, four things are occurring in the following order: 

  1. The API Test Case will send a request through GMUS API and receive a response containing positive test data.
  2. The positive test data will be used to add a new user to the GenRocket Bank application.
  3. The API Test Case will send a request through GMUS API and receive a response containing negative test data (e.g., SSN value = 001*01*0001).
  4. The negative test data will be used to add a new user to the GenRocket Bank application. An error will be received. 



Step 7 - Create a Profile for Executing the Project

  • Select Execute for the Project.


  • Select Create Profile to create an Execution Profile.


  • Enter a Profile Name, select E2E Flow, and select the Module.
  • Click Save.



Step 8 - Execute End to End Project

Once set up, it is time to execute the End to End Project. Select the proper Project Name and then click Execute for the right profile.



Select a value to execute on. For this example, it is executed locally.


During the test, it will automatically log into the application, navigate to the Add User form, enter the positive test data, and save the user.




This process will repeat for adding a user with negative test data. 




Step 9 - View Reports

After executing, you can view the reports to see the test results.