提交 1894682c 编写于 作者: P Paul Nikitochkin

Cleanup belongs to tests

simplified logic to calculate number of queries by using assert_queries
上级 f3f46a6f
......@@ -391,8 +391,7 @@ def test_polymorphic_setting_foreign_key_after_nil_target_loaded
def test_dont_find_target_when_foreign_key_is_null
tagging = taggings(:thinking_general)
queries = assert_sql { tagging.super_tag }
assert_equal 0, queries.length
assert_queries(0) { tagging.super_tag }
end
def test_field_name_same_as_foreign_key
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册