Just looking at adding the ActiveRecord::Base#find! method that was spoken about a while ago now, and just wondering what's the best way to add these tests in?
My problem is that for 75% of the tests in finder_test.rb [1] I also want to ensure that find! or find_by_name! or find_by_sql! works alongside the regular finds.
I can duplicate the tests:
def test_find assert_equal(topics(:first).title, Topic.find(1).title) end
def test_find_with_bang assert_equal(topics(:first).title, Topic.find!(1).title) end
or I can just add the test in below the other one:
def test_find assert_equal(topics(:first).title, Topic.find(1).title) assert_equal(topics(:first).title, Topic.find!(1).title) end
or should it be in a new finder_with_bang.rb ?
Thoughts?
I don't want to bother making up a big patch if it has no chance of being applied.
-- tim
[1] http://dev.rubyonrails.org/svn/rails/trunk/activerecord/test/finder_test.rb