1
0
Fork 0
mirror of https://github.com/teamcapybara/capybara.git synced 2022-11-09 12:08:07 -05:00

Workaround geckdoriver/firefox issue with change event

This commit is contained in:
Thomas Walpole 2018-05-21 16:34:00 -07:00
parent 2911451916
commit 412a308317

View file

@ -169,6 +169,8 @@ Capybara::SpecHelper.spec "#fill_in" do
context 'on a pre-populated textfield with a reformatting onchange', requires: [:js] do
it 'should only trigger onchange once' do
@session.visit('/with_js')
# Click somewhere on the page to ensure focus is acquired. Without this FF won't generate change events for some reason???
@session.find(:css, 'body').click
@session.fill_in('with_change_event', with: 'some value')
# click outside the field to trigger the change event
@session.find(:css, 'body').click