develooper Front page | perl.cvs.parrot | Postings from January 2009

[svn:parrot] r35572 - trunk/t/pmc

From:
infinoid
Date:
January 14, 2009 18:29
Subject:
[svn:parrot] r35572 - trunk/t/pmc
Message ID:
20090115022905.9FE08CB9AE@x12.develooper.com
Author: infinoid
Date: Wed Jan 14 18:28:58 2009
New Revision: 35572

Modified:
   trunk/t/pmc/packfileconstanttable.t

Log:
[pdd13] Fix some descriptions in packfileconstanttable.t.  Add a sanity check
to make sure we're dealing with the right segment of the PMC.

Modified: trunk/t/pmc/packfileconstanttable.t
==============================================================================
--- trunk/t/pmc/packfileconstanttable.t	(original)
+++ trunk/t/pmc/packfileconstanttable.t	Wed Jan 14 18:28:58 2009
@@ -6,7 +6,7 @@
 use warnings;
 use lib qw( . lib ../lib ../../lib );
 use Test::More;
-use Parrot::Test tests => 2;
+use Parrot::Test tests => 3;
 use Parrot::Config;
 
 =head1 NAME
@@ -50,6 +50,23 @@
 EOF
 
 
+# sanity check we have a PackfileConstantTable
+
+pir_output_is( <<'CODE' . $get_uuid_pbc, <<'OUT', 'sanity' );
+.sub 'test' :main
+    .local pmc pf, pfdir, pftable
+    .local string name
+    pf      = _pbc()
+    pfdir   = pf.'get_directory'()
+    pftable = pfdir[2]
+    name    = typeof pftable
+    say name
+.end
+CODE
+PackfileConstantTable
+OUT
+
+
 # PackfileConstantTable.elements
 
 pir_output_is( <<'CODE' . $get_uuid_pbc, <<'OUT', 'elements' );
@@ -70,9 +87,9 @@
 OUT
 
 
-# PackfileRawSegment.get_integer_keyed_int
+# PackfileConstantTable.get_type and PackfileConstantTable.get_*_keyed_int
 
-pir_output_is( <<'CODE' . $get_uuid_pbc, <<'OUT', 'get_integer_keyed_int' );
+pir_output_is( <<'CODE' . $get_uuid_pbc, <<'OUT', 'get_type, get_*_keyed_int' );
 .sub 'test' :main
     .local pmc pf, pfdir, pftable
     .local int size, this, type



nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About