summaryrefslogtreecommitdiff
path: root/test/ruby/test_method.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/ruby/test_method.rb')
-rw-r--r--test/ruby/test_method.rb11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/ruby/test_method.rb b/test/ruby/test_method.rb
index c30705cb15..ef28098dce 100644
--- a/test/ruby/test_method.rb
+++ b/test/ruby/test_method.rb
@@ -11,8 +11,13 @@ class TestMethod < Test::Unit::TestCase
class Base
def foo() :base end
+ def bar() :bar end
+ end
+ module SuperBar
+ def bar() super end
end
class Derived < Base
+ include SuperBar
def foo() :derived end
end
@@ -39,4 +44,10 @@ class TestMethod < Test::Unit::TestCase
um.bind(Base.new)
end
end
+
+ def test_method_super
+ assert_nothing_raised do
+ assert_equal(:bar, Derived.new.method(:bar).call)
+ end
+ end
end