input_helper.rb 215 Bytes
Newer Older
1 2 3
# see app/assets/javascripts/test_utils/simulate_input.js

module InputHelper
Mike Greiling's avatar
Mike Greiling committed
4
  def simulate_input(selector, input = '')
5 6 7
    evaluate_script("window.simulateInput(#{selector.to_json}, #{input.to_json});")
  end
end