1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
rails--rails/activerecord/test
Jon Leighton bf2df6e7ba Allow Relation#merge to take a proc.
This was requested by DHH to allow creating of one's own custom
association macros.

For example:

    module Commentable
      def has_many_comments(extra)
        has_many :comments, -> { where(:foo).merge(extra) }
      end
    end

    class Post < ActiveRecord::Base
      extend Commentable
      has_many_comments -> { where(:bar) }
    end
2012-08-03 11:05:31 +01:00
..
active_record/connection_adapters Simplify AR configuration code. 2012-06-15 19:15:36 +01:00
assets Added test to illustrate bad binary blobs. 2012-01-31 13:45:00 -06:00
cases Allow Relation#merge to take a proc. 2012-08-03 11:05:31 +01:00
fixtures Improve the derivation of HABTM assocation join table names 2012-06-22 06:27:11 +01:00
migrations stop depending on the filesystem for interleaved migration tests 2012-01-13 14:33:59 -08:00
models Deprecate :finder_sql, :counter_sql, :insert_sql, :delete_sql. 2012-08-01 19:46:31 +01:00
schema Modity the :json_data_empty attribute from :null => false to :null => true 2012-07-28 04:43:04 +09:00
support Remove IdentityMap 2012-03-13 20:08:54 -03:00
.gitignore
config.example.yml Simulated & actual (manual/skipped) PostgreSQL auto-reconnection tests. 2012-07-16 09:55:20 -07:00
config.rb