Rails edge (5) and Formtastic 2.3.x fixes

2.3-stable is failing build on edge Rails, so I wanted to see what it would take to add support. Known issues so far:

- [x] Different nokogiri versions for Ruby < 1.9.3 — Rails 5 requires nokogiri >= 1.6.0, but this requires Ruby 1.9.2 and Formtastic 2.3 still supports Ruby 1.8.7, so were testing the Ruby version in `formtastic.gemspec`
- [x] Some mock fixes already resolved in 1aed21b needed to be copied over