[macruby-changes] [2452] MacRuby/trunk/test_vm/dispatch.rb
source_changes at macosforge.org
source_changes at macosforge.org
Tue Sep 1 13:57:49 PDT 2009
Revision: 2452
http://trac.macosforge.org/projects/ruby/changeset/2452
Author: eloy.de.enige at gmail.com
Date: 2009-09-01 13:57:49 -0700 (Tue, 01 Sep 2009)
Log Message:
-----------
Added failing test_vm test about super'ing to multiple included mods. Test by Alexey Borzenkov.
Modified Paths:
--------------
MacRuby/trunk/test_vm/dispatch.rb
Modified: MacRuby/trunk/test_vm/dispatch.rb
===================================================================
--- MacRuby/trunk/test_vm/dispatch.rb 2009-09-01 20:57:40 UTC (rev 2451)
+++ MacRuby/trunk/test_vm/dispatch.rb 2009-09-01 20:57:49 UTC (rev 2452)
@@ -56,6 +56,14 @@
p Z.new.foo
}
+assert "true", %{
+ class X; def foo(x); x; end; end
+ module M1; def foo(x); super(true); end; end
+ module M2; def foo(x); return false if x; super; end; end
+ class Y < X; include M1; include M2; def foo; super(false); end; end
+ p Y.new.foo
+}
+
assert "42", "def foo; 42; end; p send(:foo)"
assert "42", "def foo(x, y); x + y; end; p send(:foo, 40, 2)"
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macruby-changes/attachments/20090901/0c294f76/attachment.html>
More information about the macruby-changes
mailing list