0% found this document useful (0 votes)
53 views3 pages

Data Driven Framework:: Property Files, XML Files, Excel Files, Text Files, CSV Files, ODBC Repositories

1. Data-driven testing frameworks store test data like input values and expected outputs in external files like Excel sheets, separating the test data from the test scripts. This reduces the number of scripts needed and increases flexibility. 2. Keyword-driven testing further separates keywords that define test actions into external files. Keywords are independent of the automation tool and can be reused across tests. 3. Keyword-driven frameworks are most appropriate when initial setup is time-consuming but pays off in long-term maintenance due to insulation from tool and application changes. Hybrid frameworks can combine keywords in Excel with data providers for additional benefits.

Uploaded by

Niha Ch
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
53 views3 pages

Data Driven Framework:: Property Files, XML Files, Excel Files, Text Files, CSV Files, ODBC Repositories

1. Data-driven testing frameworks store test data like input values and expected outputs in external files like Excel sheets, separating the test data from the test scripts. This reduces the number of scripts needed and increases flexibility. 2. Keyword-driven testing further separates keywords that define test actions into external files. Keywords are independent of the automation tool and can be reused across tests. 3. Keyword-driven frameworks are most appropriate when initial setup is time-consuming but pays off in long-term maintenance due to insulation from tool and application changes. Hybrid frameworks can combine keywords in Excel with data providers for additional benefits.

Uploaded by

Niha Ch
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 3

Difference between Keyword driven and Data driven framework :

Data Driven Framework :


It is nothing but data driven test, performing the same functionality with multiple input
values by using parametarization with the help of data table or data source is called Data
Driven Test.

While automating or testing any application, at times it may be required to test the same
functionality multiple times with the different set of input data. Thus, in such cases, we
can’t let the test data embedded in the test script. Hence it is advised to retain test data
into some external data base outside the test scripts.

Data Driven Testing Framework helps the user segregate the test script logic and the test
data from each other. It lets the user store the test data into an external database. The
external databases can be property files, xml files, excel files, text files,
CSV files, ODBC repositories etc. The data is conventionally stored in “Key-Value”
pairs. Thus, the key can be used to access and populate the data within the test scripts.
Ex: Let us consider the “Gmail – Login” Functionality.
First and the foremost step are to create an external file that stores the test data (Input
data and Expected Data). Let us consider an excel sheet for instance.

Pros:
 The most important feature of this framework is that it considerably reduces the
total number of scripts required to cover all the possible combinations of test
scenarios. Thus lesser amount of code is required to test a complete set of scenarios.
 Any change in the test data matrix would not hamper the test script code.
 Increases flexibility and maintainability.
 A single test scenario can be executed altering the test data values.
Keyword Driven Testing Framework:
The Keyword driven testing framework is an extension to Data driven Testing
Framework in a sense that it not only segregates the test data from the scripts, it also
keeps the certain set of code belonging to the test script into an external data file.

These set of code are known as Keywords and hence the framework is so named. Key
words are self-guiding as to what actions needs to be performed on the application.

The keywords and the test data are stored in a tabular like structure and thus it is also
popularly regarded as Table driven Framework. Take a notice that keywords and test
data are entities independent of the automation tool being used.

Ex: For example keywords like login, clickLink and verifyLink are defined within
the code.
Pros:
 In addition to advantages provided by Data Driven testing, Keyword driven
framework doesn’t require the user to possess scripting knowledge unlike Data
Driven Testing.
 A single keyword can be used across multiple test scripts.

Purpose of keyword driven frameworks compared to data driven frameworks.


Keyword-driven testing is a technique that separates much of the programming work
from the actual test steps so that the test steps can be developed earlier and can often
be maintained with only minor updates, even when the application or testing needs
change significantly. The keyword-driven testing methodology divides test creation into
two stages: Planning Stage, Implementation Stage

Data- Driven testing is a framework where test input and output values are read from
data files (datapools, ODBC sources, csv files, Excel files, DAO objects, ADO objects,
and such) and are loaded into variables in captured or manually coded scripts. In this
framework, variables are used for both input values and output verification values.
Navigation through the program, reading of the data files, and logging of test status and
information are all coded in the test script.

What circumstances would make a keyword-driven framework more appropriate for an


automated test suite than a data-driven framework?
The keyword driven automation framework is initially the hardest and most time-
consuming data driven approach to implement. After all, we are trying to fully insulate
our tests from both the many failings of the automation tools, as well as changes to the
application itself.

To accomplish this, we are essentially writing enhancements to many of the component


functions already provided by the automation tool: such as error correction, prevention,
and enhanced synchronization.

Fortunately, this heavy, initial investment is mostly a one-shot deal. Once in place,
keyword driven automation is arguably the easiest of the data driven frameworks to
maintain and perpetuate providing the greatest potential for long-term success.

For More Understanding read


thishttp://safsdev.sourceforge.net/FRAMESDataDrivenTestAutomationFrameworks.htm
Hybrid Test Framework
Hybrid Test framework is a concept where we are using the advantage of both
Keyword and Data driven framework.

Here for keywords, we will use Excel files to maintain test cases, and for test
data, we can use data, provider of Testng framework.

You might also like