Verify text in html towards predefined text

Hi,

There are a lot of solution for this.
Personnaly I use pandas library that manages .csv files.
You can simply read/load the file at the beginning of the test, then loop on each row, calling the column by their titles.

*** Settings ***
Library             SeleniumLibrary
Library             pandas

*** Variables ***
${INPUT_CSV}         ./Data/datafile.csv

*** Test Cases ***
Read File
    ${data}    Read Csv    ${INPUT_CSV}     encoding=UTF-8
    ${num_rows}    Get Length    ${data}
    FOR  ${i}  IN RANGE   0    ${num_rows}
        Log    ${data['name'][${i}]}
    END
  • Remember index start to 0
  • Column names/keys are case sensitive, so here my colum is named “name”, if you use “Name” it won’t work.

You can also search the forum, there are some excel or other alternatives can could suit.
And btw if you only use Seleniumlibrary, you can use only Get Text keyword, it will ease the read of test cases.

Regards
Charlie