diff options
Diffstat (limited to 'activeresource/test/base_test.rb')
-rw-r--r-- | activeresource/test/base_test.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/activeresource/test/base_test.rb b/activeresource/test/base_test.rb index 6a6ee5c64b..e9bf5d70b3 100644 --- a/activeresource/test/base_test.rb +++ b/activeresource/test/base_test.rb @@ -178,6 +178,14 @@ class BaseTest < Test::Unit::TestCase assert_kind_of Person, matz assert_equal "Matz", matz.name end + + def test_respond_to + matz = Person.find(1) + assert matz.respond_to?(:name) + assert matz.respond_to?(:name=) + assert matz.respond_to?(:name?) + assert !matz.respond_to?(:java) + end def test_find_by_id_with_custom_prefix addy = StreetAddress.find(1, :params => { :person_id => 1 }) |