Closed Ecco closed 4 years ago
FWIF, I've found a workaround by abusing drag_to
, which has a customizable delay. Here goes:
button = find("button")
button.drag_to(button, delay: 0.5)
It's a bit weird though, and since drag_to has a delay, maybe it'd make sense to add one to click too?
This should be proposed for Capybara rather than for a specific driver, and if doing it for click it should also potentially be looked at for double_click, although I'm not really sure how that would actually work.
Sure! Here goes: teamcapybara/capybara#2324
Implemented in apparition via 9346705d656a1ab87371b1f340a120033c4fb4c6
Hi there!
I don't know if this feature request should go into Capybara or Apparition, but here goes.
I'm testing a webpage which is sensitive to the speed at which a button is clicked. Weird, I know, but well, it's kinda simple actually : we just listen for "mouseup" and "mousedown" events, and act accordingly.
It would be awesome if we could do something like:
and this would yield a 0.5 second pause between
down
andup
inCapybara::Apparition::Mouse#click_at
😄