Skip to content

Commit

Permalink
Remove some warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
rafaelfranca committed Nov 24, 2014
1 parent 8fe1aec commit d91420f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions activerecord/test/cases/finder_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,10 @@ def test_find
end

def test_find_with_proc_parameter_and_block
e = assert_raises(RuntimeError) do
error = assert_raises(RuntimeError) do
Topic.all.find(-> { raise "should happen" }) { |e| e.title == "non-existing-title" }
end
assert_equal "should happen", e.message
assert_equal "should happen", error.message

assert_nothing_raised(RuntimeError) do
Topic.all.find(-> { raise "should not happen" }) { |e| e.title == topics(:first).title }
Expand Down
2 changes: 1 addition & 1 deletion activerecord/test/cases/relation/merging_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ class MergingDifferentRelationsTest < ActiveRecord::TestCase
rating_1 = comment_1.ratings.create!

comment_2 = dev.comments.create!(body: "I'm John", post: Post.first)
rating_2 = comment_2.ratings.create!
comment_2.ratings.create!

assert_equal dev.ratings, [rating_1]
end
Expand Down

0 comments on commit d91420f

Please sign in to comment.