diff options
Diffstat (limited to 'test/ruby/test_class.rb')
-rw-r--r-- | test/ruby/test_class.rb | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/test/ruby/test_class.rb b/test/ruby/test_class.rb index 38a6e9eb9f..456362ef21 100644 --- a/test/ruby/test_class.rb +++ b/test/ruby/test_class.rb @@ -721,9 +721,13 @@ class TestClass < Test::Unit::TestCase assert_separately([], "#{<<~"begin;"}\n#{<<~"end;"}") begin; - Date = (class C\u{1f5ff}; self; end).new + module Bug + module Class + TestClassDefinedInC = (class C\u{1f5ff}; self; end).new + end + end assert_raise_with_message(TypeError, /C\u{1f5ff}/) { - require 'date' + require '-test-/class' } end; end |