Added tests for ActiveRecord 4.0