- If you want to click at certain point on a map
- If you want to click at certain point on a canvas, colour select etc.
- Capybara: v2.18, v3.0, v3.5
- Drivers: Selenium, Webkit, Poltergeist
Add this line to your application's Gemfile:
group :test do
gem 'capybara-click_at'
end
And then execute:
$ bundle
Or install it yourself as:
$ gem install capybara-click_at
In your spec_helper.rb
RSpec.configure do |config|
config.include CapybaraClickAt
end
In your env.rb
World CapybaraClickAt
click_at(5, 5)
click_at(5, 5, css: '#map')
click_at(5, 5, xpath: '//div[@id="select-colour"]')
- Add a test case which covers the bug
- Add code which makes the test green
- Open pull request
The gem is available as open source under the terms of the MIT License.