What Is Data Driven Framework In Selenium WebDriver

Selenium WebDriver Data Driven Framework

Meaning Of data driven keyword In any automation framework Is your test cases and suite will be driven by external data set feed. Data feed can be any type of data sheets like xls file, xlsx file, csv file etc. Main concept of data driven framework Is your test case will remain unchanged even If you change number of
data set combinations In data sheet. Means your test case should run If you feed only 1 data set combination and also It should run for 100 or more data set combinations. You can use data driven framework when you wants to perform same action with multiple set of data.

I am suggesting you to read java and WebDriver Tutorials PART 1 and PART 2 before learning webdriver data driven framework better to understand It better.

Simple example of where we can use data driven framework Is supposing you are testing G-mail Log In function with 100 different usernames and passwords to check which username and password Is valid and which Is Invalid or wrong. This Is just example. Another simple example Is testing of calculator application's different button's function to verify that each and every button Is working fine and getting correct result when doing Summation, Subtraction, Multiplication or Division of two or more numbers.

Selenium WebDriver data driven Framework should be designed In such a way by which you can perform bellow given tasks with your test cases or suite.

  • You should be able to place a condition In Test Suite List Sheet to decide that Specific Test Suite should be Executed or Not.
  • You should be able to place a condition In Test Case List Sheet to decide that Specific Test Case should be Executed or Not.
  • You should be able to place a condition In Test Data List Sheet to decide that Specific Test data line should be Executed or Not.
  • Your test case should Execute For Multiple Lines Of Test Data.
  • It should be Able To Report Result In Test Data List Sheet that Test Case For Specific Data Set Line Is Pass or Fail or Skip.
  • It should be Able To Report Result In Test Case List Sheet that Test Case Is Pass or Fail or Skip.
Excluding above features of Selenium WebDriver data driven Framework, It should also pass or fail Test case In testng reports and XSLT reports.

So now we are going to create this kind of Selenium WebDriver data driven Framework step by step. I will describe you how to setup data driven framework for selenium webdriver from scratch. My next post will describe you how to start It.

3 comments: