How to handle element not visible exception in selenium