aboutsummaryrefslogtreecommitdiffstats
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.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/test/ruby/test_class.rb b/test/ruby/test_class.rb
index efee102835..4f7e037580 100644
--- a/test/ruby/test_class.rb
+++ b/test/ruby/test_class.rb
@@ -529,5 +529,10 @@ class TestClass < Test::Unit::TestCase
assert_raise_with_message(TypeError, /is not a class/) {
m.module_eval "class A; end"
}
+ n = "M\u{1f5ff}"
+ m.module_eval "#{n} = 42"
+ assert_raise_with_message(TypeError, "#{n} is not a class") {
+ m.module_eval "class #{n}; end"
+ }
end
end