How to verify whether the image is present or not on Selenium java cucubmer
if(driver.findElement(By.xpath("xpath of
image")).getAttribute("src").contains("image file name present in the html
source"));
it just verifies that the given image link present in the html source or
not. To verify that whether the image is displayed or not, you try to use
isDisplayed() command.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment