In my case, I have a table that displays records of school districts. My goal is to use Selenium in order to select the delete icon positioned in the eighth td for the district located on a row with a specific name. In this scenario, the name being QA__run
and it should be found in the first td
How can I achieve this task effectively?
I already attempted:
//table[@id='districts']//tr//td//a[contains[text(),'QA__run (Selected)']]
as well as
//table[@id='districts']//tr//td//a[contains[text(),"*QA__run*"]]
However, neither selector seemed to work for me.
Currently, the closest solution I found was:
//table[@id='districts']//tr//td
This selects the first td of the first tr but isn't quite specific enough for my needs
The layout of the table is as follows: