0

I have test case to pass the value in input fields (2 fields) then click the submit button. I have test data file in which multiple values are stored and I want to run the test case multiple time based on data in text file and pass the different value in input field which is stored in text file.

@Test
public void dosomework()
{
    driver.findElement(By.id("field1")).sendKeys(AccountName);
    driver.findElement(By.id("field2")).sendKeys(AccountName);
}

Text file
a1,b1
a2,b2
a3,b3

As per above file test case should run 3 times with these values. How can I achieve this?

sudha vedi
  • 97
  • 1
  • 11
  • Where is your code that attempts to use the data? – JeffC Aug 31 '17 at 17:08
  • I have various username and password in my text file (comma delimited) and want to verify all the username and password by selenium? How can I do that? – sudha vedi Aug 31 '17 at 18:50

0 Answers0