From 36b7f3ae5bce6443a1928ec7194ff611eb2232b5 Mon Sep 17 00:00:00 2001 From: Ryuta Kamizono Date: Tue, 25 Jul 2017 03:25:23 +0900 Subject: Fix `warning: assigned but unused variable - comment` ``` % ARCONN=sqlite3 be ruby -w -Itest test/cases/associations/belongs_to_associations_test.rb -n test_multiple_counter_cache_with_after_create_update test/cases/associations/belongs_to_associations_test.rb:1181: warning: assigned but unused variable - comment Using sqlite3 Run options: -n test_multiple_counter_cache_with_after_create_update --seed 49644 . Finished in 0.114266s, 8.7515 runs/s, 17.5030 assertions/s. 1 runs, 2 assertions, 0 failures, 0 errors, 0 skips ``` --- activerecord/test/cases/associations/belongs_to_associations_test.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'activerecord/test/cases/associations/belongs_to_associations_test.rb') diff --git a/activerecord/test/cases/associations/belongs_to_associations_test.rb b/activerecord/test/cases/associations/belongs_to_associations_test.rb index 4f9d5ee3fa..0f7a249bf3 100644 --- a/activerecord/test/cases/associations/belongs_to_associations_test.rb +++ b/activerecord/test/cases/associations/belongs_to_associations_test.rb @@ -1178,7 +1178,7 @@ class BelongsToAssociationsTest < ActiveRecord::TestCase assert_difference "parent.reload.children_count", +1 do assert_difference "post.reload.comments_count", +1 do - comment = CommentWithAfterCreateUpdate.create(body: "foo", post: post, parent: parent) + CommentWithAfterCreateUpdate.create(body: "foo", post: post, parent: parent) end end end -- cgit v1.2.3