I am using capybara to click a checkbox, however it can\'t seem to find it no matter what I do. I am able to correctly find both the span and the label inside the span, but
I had the exact issue yesterday. Capybara was automatically ignoring the input due to it being invisible. I solved it with the following:
find('#agreement', :visible => false).click
You can also add the following to env.rb to enable Capybara to interact with all hidden elements:
Capybara.ignore_hidden_elements = false