Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

added regression test

  • Loading branch information...
commit 1df2286f81590c6fcf707e54fa8d647974641531 1 parent 152c41d
@sirlantis authored
View
4 activerecord/test/cases/associations/has_many_through_associations_test.rb
@@ -471,6 +471,10 @@ def test_count_has_many_through_with_named_scope
assert_equal 1, authors(:mary).categories.general.count
end
+ def test_has_many_through_on_new_record
+ assert_equal [], Post.new.tags.all
+ end
+
def test_joining_has_many_through_belongs_to
posts = Post.joins(:author_categorizations).
where('categorizations.id' => categorizations(:mary_thinking_sti).id)
Please sign in to comment.
Something went wrong with that request. Please try again.