Support for ActiveRecord 4.0.x

:warning: **This is not a complete pull request, and it should not be merged into the master branch!** :warning:

I chose master as the base branch because there is not an "ar_4.0.x" branch in the CPK repository like there is for Rails 3.1 and 3.2.

I'm starting an incomplete pull request because I would not be shocked to learn that a lot of people are already working on compatibility with Rails 4.0, and we are working in isolation instead of having a central body of knowledge.

So far, I've added a few of the obvious cases which I needed to get all of my own app's tests passing. There is a little I've left out, because for the moment they are horrible kludges, but I will fix them and include them too!

After that, I'll begin focusing on the MySQL tests, then Postgres, then whatever other DBs are supported. 

Someone else feel free to join in. I guess fork my ar_4.0.x branch and make pull requests there? Or get with me and I'll assign you collaborator access to commit directly. 

Once we get far enough, we'll update this Pull Request for review by the CPK team.

:+1: ?