From the course: Cucumber Essential Training

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Data table: List of list of strings

Data table: List of list of strings

From the course: Cucumber Essential Training

Start my 1-month free trial

Data table: List of list of strings

So let's go ahead and define another scenario, and this time we are going to have more than one row. So let's go ahead and copy this, paste it here, and I'm going to call it @ListofListofStrings. And let's add an additional row here without any header. So, paste and let's put Cucumber Salad here, one unit, $15... and this is going to cost $55. So this time, the data will be presented to us in form of a list of a list of strings. So, I'm going to save this and go ahead and use this tag... to put it in our test file. But before we go ahead and run this test, let's go ahead and fix our steps... here. So, this time we have a list of list of strings. So, I'm going to change this here to read a list of list of strings and change the first parameter data type to list of list of strings. Now, this data has to be read in two loops. So the first loop now will be a list of strings, so... like this. I'm going to call it BillItems, and I'm going to introduce a second loop inside. And inside here…

Contents