[svn:parrot] r41527 - trunk/t/pmc
NotFound at svn.parrot.org
NotFound at svn.parrot.org
Sun Sep 27 11:32:21 UTC 2009
Author: NotFound
Date: Sun Sep 27 11:32:21 2009
New Revision: 41527
URL: https://trac.parrot.org/parrot/changeset/41527
Log:
[t] cover RSA.delete_keyed
Modified:
trunk/t/pmc/resizablestringarray.t
Modified: trunk/t/pmc/resizablestringarray.t
==============================================================================
--- trunk/t/pmc/resizablestringarray.t Sun Sep 27 11:12:06 2009 (r41526)
+++ trunk/t/pmc/resizablestringarray.t Sun Sep 27 11:32:21 2009 (r41527)
@@ -23,7 +23,7 @@
.include 'test_more.pir'
# set a test plan
- plan(259)
+ plan(261)
'size/resize'()
'clone'()
@@ -38,6 +38,8 @@
'get_integer_keyed'()
'get_number_keyed'()
+ 'delete_keyed'()
+
'push_pmc'()
'push_string'()
'push_integer'()
@@ -664,12 +666,33 @@
.end
#
+# test delete_keyed
+#
+.sub 'delete_keyed'
+ .local pmc array
+ array = new ['ResizableStringArray']
+ array[0] = "one"
+ array[1] = "two"
+ array[2] = "three"
+ $P0 = new ['Integer']
+ $P0 = 1
+ delete array[$P0]
+ $I0 = elements array
+ $S0 = array[1]
+ is($I0, 2, "delete_keyed - elements")
+ is($S0, "three", "delete_keyed - value")
+.end
+
+#
# test pushing PMCs onto the array
#
.sub 'push_pmc'
.local pmc array
array = new ['ResizableStringArray']
+ .local pmc array
+ array = new ['ResizableStringArray']
+
array = 0
$P0 = new ['String']
$P0 = "one"
More information about the parrot-commits
mailing list