summaryrefslogtreecommitdiff
path: root/test/ruby/test_class.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/ruby/test_class.rb')
-rw-r--r--test/ruby/test_class.rb7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/ruby/test_class.rb b/test/ruby/test_class.rb
index 93a19e86e9..bc0f79a681 100644
--- a/test/ruby/test_class.rb
+++ b/test/ruby/test_class.rb
@@ -144,4 +144,11 @@ class TestClass < Test::Unit::TestCase
assert_raise(TypeError) { Class.allocate.new }
assert_raise(TypeError) { Class.allocate.superclass }
end
+
+ def test_nonascii_name
+ c = eval("class ::C\u{df}; self; end")
+ assert_equal("C\u{df}", c.name, '[ruby-core:24600]')
+ c = eval("class C\u{df}; self; end")
+ assert_equal("TestClass::C\u{df}", c.name, '[ruby-core:24600]')
+ end
end