summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2016-08-16 05:56:26 +0000
committerusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2016-08-16 05:56:26 +0000
commitcaec808f74a7545cc2b6930dbfa629071315f065 (patch)
treef65c273b5395df1fb633730972351f8cadc2b06e /test
parent0d09e1af49b8523a13bc6e5e054000195114b4f0 (diff)
merge revision(s) 55705: [Backport #12345]
* variable.c (rb_local_constants_i): exclude private constants when excluding inherited constants too. [Bug #12345] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@55930 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test')
-rw-r--r--test/ruby/test_module.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/test/ruby/test_module.rb b/test/ruby/test_module.rb
index b70e6666ff..3aecccabed 100644
--- a/test/ruby/test_module.rb
+++ b/test/ruby/test_module.rb
@@ -1360,6 +1360,8 @@ class TestModule < Test::Unit::TestCase
def test_constants_with_private_constant
assert_not_include(::TestModule.constants, :PrivateClass)
+ assert_not_include(::TestModule.constants(true), :PrivateClass)
+ assert_not_include(::TestModule.constants(false), :PrivateClass)
end
def test_toplevel_private_constant