diff options
Diffstat (limited to 'activerecord/test')
-rw-r--r-- | activerecord/test/cases/associations_test.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/activerecord/test/cases/associations_test.rb b/activerecord/test/cases/associations_test.rb index c0f1945cec..d7f25f760e 100644 --- a/activerecord/test/cases/associations_test.rb +++ b/activerecord/test/cases/associations_test.rb @@ -289,6 +289,14 @@ class OverridingAssociationsTest < ActiveRecord::TestCase DifferentPeopleList.reflect_on_association(:has_one) ) end + + def test_requires_symbol_argument + assert_raises ArgumentError do + Class.new(Post) do + belongs_to "author" + end + end + end end class GeneratedMethodsTest < ActiveRecord::TestCase |