ChromeDriver clicking works by simulating a mouse click in the middle of the element's first client rect (or bounding client rect if it doesn't have a first client rect). ( Clicking issues Show archive.org snapshot )
So if you are trying to click on an element, chromedriver
tries to click at the position where it first finds that element.
This can lead to some problems and unexpected behavior like:
Element is not clickable at point ...
errosA step which finds and clicks the desired link via javascript may solve the problem:
When(/^I search and click on "([^"]*)"$/) do |text|
page.execute_script("$(\":contains('#{text}'):not(:has(:contains('#{text}')))\").click()")
end
Note:
The bug Show archive.org snapshot seemed to appear in chromedriver versions > 2.12