Rails 4 compatibility

@derekprior I'm going to go ahead and start a PR on this. Commits needs to be cleaned up / squashed and I'm not sure whether or not to stick with RailsShim but I figure we can play with that here.

Regardless all tests are passing now, on all appraisals.