[svn:parrot] r46083 - trunk/t/oo

coke at svn.parrot.org coke at svn.parrot.org
Tue Apr 27 23:12:28 UTC 2010


Author: coke
Date: Tue Apr 27 23:12:27 2010
New Revision: 46083
URL: https://trac.parrot.org/parrot/changeset/46083

Log:
Add a test for TT #1596

Modified:
   trunk/t/oo/methods.t

Modified: trunk/t/oo/methods.t
==============================================================================
--- trunk/t/oo/methods.t	Tue Apr 27 22:49:55 2010	(r46082)
+++ trunk/t/oo/methods.t	Tue Apr 27 23:12:27 2010	(r46083)
@@ -21,12 +21,14 @@
 
     create_library()
 
-    plan(5)
+    plan(6)
 
     loading_methods_from_file()
     loading_methods_from_eval()
     overridden_find_method()
 
+    overridden_core_pmc()
+
     delete_library()
 
 .end
@@ -126,6 +128,26 @@
 
 .namespace []
 
+.sub 'overridden_core_pmc'
+    .local string msg
+    msg = "able to invoke overridden method on core PMC (TT #1596)"
+    $P0 = new 'ResizablePMCArray'
+    push_eh jic
+        $I0 = $P0.'foo'()
+        is($I0, 1, msg) 
+        .return()
+  jic:
+    pop_eh
+    # remove the exception handler and the todo when this test passes
+    # so that future regressions are noisy.
+    todo('','cannot find method', msg)
+.end
+
+.namespace ['ResizablePMCArray']
+.sub 'foo' :method
+    .return(1)
+.end
+
 # Local Variables:
 #   mode: pir
 #   fill-column: 100


More information about the parrot-commits mailing list