rails/rails — pull request #9332 by wangjohn (2013-02-20 05:24:06+00:00)
Title: Tests to make sure empty arguments in WhereChain raise errors

Added a bunch of tests to make sure that the check_empty_arguments method has the desired functionality. In particular, we want to make sure that following is true:

Post.references() # => raises error
Post.references([]) # => does not raise an error from check_empty_arguments

Also, modified my CHANGELOG entry (because it was actually incorrect and had an example of incorrect behavior).

Finally, check_empty_arguments now takes in args, instead of *args, which makes it easier for a method to manipulate the args before they get sent on to check_empty_arguments. This just allows for easier use in the future.