Understanding Test Automation Frameworks Part 3

Posted By : Aditi Nahar | 29-May-2018

In my last article, I discussed “structured scripting framework” which uses structured programming instructions like the control structures for controlling a different flow of the test cases or test scripts.

In this article, I will discuss third automation framework i.e. “Data Driven Automation Framework”. I will explain in brief about this framework, how it is useful and Merits and Demerits in using it.

 

Data Driven Automation Framework

As the name says, in this framework, automation test scripts are driven by data i.e. data files are used to fetch input and output test values. The test data can be stored in any of the external databases like text files, xml files, excel sheets, csv files, property files. While testing an application it is required to test a functionality multiple times with multiple test data so, in that case, each test data cannot be put in test scripts as this will be time consuming and inefficient. Therefore, data is stored in external database thus segregating test data and test script logic.

Test Scripting can also be done using Linear scripting framework.

 

 
 
 

It is very convenient and useful to keep test data in external storages as a user can easily prepare it, modify it and also share it with another person. For eg have a look at the below table in which data is stored in an excel sheet.

 

Each row holds a test data for one test script and can be checked or assigned. However, multiple rows can also be used.

 

Now let’s have a look at the operations in a data-driven test

1. Fetching input data from the storage file.

2. Entering the same data into application script.

3. Writing back the output in the file.

4. Verifying the actual result with the expected Result.

5. Picking next set of input test data.    

 

In my coming blogs, we will see how to perform these steps with an example.

 

Every framework has some advantages and disadvantages associated with them. Let’s see them for this framework:

Merits:

1. Test script size is reduced.

2. Change in test data does not affect test script logic.

3. Code maintainability and flexibility increases.

4. Multiple test scenarios can be executed with a particular test script.

5. Supports better error handling as the function returns TRUE or FALSE values instead of aborting the script.

 

Demerits:

1. Proficiency is required in writing the scripts.

2. Data files need to be maintained for each test case.

3. Data files need to be handled properly in order to avoid script processing errors.

 

 

In my next blog, I will discuss the implementation of Data Driven Automation Framework with Selenium Webdriver.

Hope you are enjoying reading about different automation frameworks.

Happy Reading:)

 
Related Tags

About Author

Author Image
Aditi Nahar

Aditi is a certified QA Engineer with a strong command over management tool sets like JIRA and Trello, as well as QA tool sets for API and performance testing. She possesses excellent verbal and written communication skills and has gained valuable experience in management and leadership while collaborating with clients and large teams. Aditi's ability to apply creative thinking and problem-solving skills makes her adept at handling challenging business scenarios. Her proficiency in manual testing has proven instrumental in identifying issues and ensuring the functionality of applications across web, mobile, and TV platforms. She has made significant contributions to both internal and client projects, including Bits2Btc, AUS-BTC, EZBitex, ACL EAP, Scaffold, Iron Systems VRP, Oremus Zoho, and NOWCAST OTT.

Request for Proposal

Name is required

Comment is required

Sending message..