summaryrefslogtreecommitdiff
path: root/yarvtest/test_class.rb
diff options
context:
space:
mode:
Diffstat (limited to 'yarvtest/test_class.rb')
-rw-r--r--yarvtest/test_class.rb19
1 files changed, 19 insertions, 0 deletions
diff --git a/yarvtest/test_class.rb b/yarvtest/test_class.rb
index 1eab39f0d5..488b3ccfd9 100644
--- a/yarvtest/test_class.rb
+++ b/yarvtest/test_class.rb
@@ -749,5 +749,24 @@ class TestClass < YarvTestBase
:ok
}
end
+
+ def test_ivar2
+ ae %q{
+ class C
+ def initialize
+ @_c = 1
+ end
+ end
+
+ class D < C
+ def initialize
+ super
+ @_d = 2
+ end
+ end
+
+ D.new.instance_variables
+ }
+ end
end