mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
test/eval.c: add test for #5528
This commit is contained in:
@@ -158,4 +158,7 @@ assert('Module#class_eval with string') do
|
||||
cc = c.new
|
||||
assert_true cc.respond_to?(:foo)
|
||||
assert_equal 42, c.new.foo
|
||||
|
||||
b = c.class_eval("class A; def a; 55; end; end; class B; def b; A; end; end; B")
|
||||
assert_equal 55, b.new.b.new.a
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user