Selenium Webdriver isDisplayed() method?

I am using Selenium Webdriver with Java I am testing a web page in which I need to test if link is present. I am using isDisplayed() method which returns true if link is present and false if it is not present. Problem with this is if element is not present whole script fails since it tries to look for that... show more I am using Selenium Webdriver with Java

I am testing a web page in which I need to test if link is present. I am using isDisplayed() method which returns true if link is present and false if it is not present. Problem with this is if element is not present whole script fails since it tries to look for that element. Is there way I can pass the testcase or move to next step even if isDisplayed() returns false.

Thanks
4 answers 4