calebhearth / formulaic

Simplify form filling with Capybara
MIT License
552 stars 29 forks source link

Make date input field name gsub indepedent of select box order #33

Closed rossta closed 10 years ago

rossta commented 10 years ago

Date field label target may be tied to any of the day, month, year select box inputs; for example, simple_form chooses the first: https://github.com/plataformatec/simple_form/blob/6f2a61015098d43baac67a5f64c5fb4ba9031426/lib/simple_form/inputs/date_time_input.rb#L20

This minor change ensures the matcher will parse the correct field name regardless of the order.

calebhearth commented 10 years ago

Thanks! Merged in 2ee1de5.