Commit 21c15d8f by Jay Zoldak

Click in the upper left of an element instead of the middle.

parent 3cec8f1a
...@@ -96,6 +96,7 @@ def assert_css_with_text(css, text): ...@@ -96,6 +96,7 @@ def assert_css_with_text(css, text):
def css_click(css): def css_click(css):
''' '''
<<<<<<< HEAD
First try to use the regular click method, First try to use the regular click method,
but if clicking in the middle of an element but if clicking in the middle of an element
doesn't work it might be that it thinks some other doesn't work it might be that it thinks some other
...@@ -106,6 +107,12 @@ def css_click(css): ...@@ -106,6 +107,12 @@ def css_click(css):
world.browser.find_by_css(css).first.click() world.browser.find_by_css(css).first.click()
except WebDriverException, e: except WebDriverException, e:
css_click_at(css) css_click_at(css)
=======
Rather than click in the middle of an element,
click in the upper left
'''
css_click_at(css)
>>>>>>> Click in the upper left of an element instead of the middle.
def css_click_at(css, x=10, y=10): def css_click_at(css, x=10, y=10):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment