summaryrefslogtreecommitdiff
path: root/test/ruby/test_marshal.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/ruby/test_marshal.rb')
-rw-r--r--test/ruby/test_marshal.rb12
1 files changed, 12 insertions, 0 deletions
diff --git a/test/ruby/test_marshal.rb b/test/ruby/test_marshal.rb
index 4dcdb605ab..722871424d 100644
--- a/test/ruby/test_marshal.rb
+++ b/test/ruby/test_marshal.rb
@@ -550,4 +550,16 @@ class TestMarshal < Test::Unit::TestCase
assert_raise(TypeError) {Marshal.load("\x04\x08IM\x1cTestMarshal::TestModule\x06:\x0e@ivar_bug\"\x08bug")}
assert_not_operator(TestModule, :instance_variable_defined?, :@bug)
end
+
+ class TestForRespondToFalse
+ def respond_to?(a)
+ false
+ end
+ end
+
+ def test_marshal_respond_to_arity
+ assert_nothing_raised(ArgumentError, '[Bug #7722]') do
+ Marshal.dump(TestForRespondToFalse.new)
+ end
+ end
end