diff options
author | Nobuyoshi Nakada <[email protected]> | 2021-01-11 00:33:26 +0900 |
---|---|---|
committer | Nobuyoshi Nakada <[email protected]> | 2021-01-11 00:33:26 +0900 |
commit | 480f436dacc28def6c23d6b914f03ac6a0753d5d (patch) | |
tree | a64fe0c1bdc609623cd20df200bb1eca67b43f62 /test/ruby/test_module.rb | |
parent | c63552eab1a13c6c05e18d763c7acf3c4c5383ed (diff) |
Suppress constant redefinition warnings
Diffstat (limited to 'test/ruby/test_module.rb')
-rw-r--r-- | test/ruby/test_module.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/test/ruby/test_module.rb b/test/ruby/test_module.rb index 43f0c51753..fac3131f42 100644 --- a/test/ruby/test_module.rb +++ b/test/ruby/test_module.rb @@ -793,6 +793,8 @@ class TestModule < Test::Unit::TestCase assert_equal(prefix+"C", m.const_get(:C).name) c = m.class_eval("Bug15891 = Class.new.freeze") assert_equal(prefix+"Bug15891", c.name) + ensure + self.class.class_eval {remove_const(:M)} end def test_private_class_method |