I have a
.
I try to write a test that myDiv has 0 text in it. With WebDriver it is:
<
You can try using the jsoup library for parsing HTML.
First just load the page content (driver.getPageSource()) to the jsoup document object and use the richness of methods of that excellent library (kudos to the author).
Example:
String pageSource = driver.getPageSource();
Document doc = Jsoup.parse(pageSource);
Elements requestsListRecords = doc.getElementsByTag("table").get(2).getElementsByTag("tr");