Author: jkeenan
Date: Thu Nov 15 15:40:52 2007
New Revision: 22840

Modified:
   trunk/t/configure/124-auto_alignptrs-05.t

Log:
Provide some additional invocations of test_step_thru_runstep() to
provide runstep() with an environment that more closely matches actual
configuration.  Thanks to Bernhard Schmalhofer for assistance in
testing.  Partial satisfaction of
http://rt.perl.org/rt3/Ticket/Display.html?id=47391.


Modified: trunk/t/configure/124-auto_alignptrs-05.t
==============================================================================
--- trunk/t/configure/124-auto_alignptrs-05.t   (original)
+++ trunk/t/configure/124-auto_alignptrs-05.t   Thu Nov 15 15:40:52 2007
@@ -5,10 +5,12 @@
 
 use strict;
 use warnings;
-use Test::More qw(no_plan); # tests => 13;
+use Test::More tests => 21;
 use Carp;
 use lib qw( lib t/configure/testlib );
 use_ok('config::init::defaults');
+use_ok('config::inter::progs');
+use_ok('config::auto::attributes');
 use_ok('config::auto::alignptrs');
 use Parrot::Configure;
 use Parrot::Configure::Options qw( process_options );
@@ -24,6 +26,8 @@
 my $conf = Parrot::Configure->new;
 
 test_step_thru_runstep( $conf, q{init::defaults}, $args );
+test_step_thru_runstep( $conf, q{inter::progs}, $args );
+test_step_thru_runstep( $conf, q{auto::attributes}, $args );
 
 my $pkg = q{auto::alignptrs};
 
@@ -31,7 +35,7 @@
 $conf->options->set( %{$args} );
 
 my ( $task, $step_name, @step_params, $step);
-$task        = $conf->steps->[1];
+$task        = $conf->steps->[3];
 $step_name   = $task->step;
 @step_params = @{ $task->params };
 
@@ -42,11 +46,11 @@
 
 {
     $conf->data->set('ptr_alignment' => undef);
-    if ($^O eq q{hpux}) { $^O = q{linux} }
+    local $^O = q{linux} if ($^O eq q{hpux});
     my $ret;
     eval { $ret = $step->runstep($conf); };
     if ($@) {
-        like($@, qr/Can't determine alignment/,
+        like($@, qr/Can't determine alignment/, #'
             "Got expected error message when runstep() failed");
     } else {
         like($step->result(), qr/bytes?/,

Reply via email to