Today I Learned

hashrocket A Hashrocket project

Fill in hidden fields with Capybara

Normally you are not able to interact with hidden fields, but you can still change the value with #set:

find("input[type=hidden]", visible: false).set("my cool value")
See More #rails TILs
Looking for help? Hashrocket has been an industry leader in Ruby on Rails since 2008. Rails is a core skill for each developer at Hashrocket, and we'd love to take a look at your project. Contact us and find out how we can help you.