Author: dagolden
Date: Mon Oct 26 20:12:43 2009
New Revision: 13430

Modified:
   Module-Build/trunk/t/properties/needs_compiler.t

Log:
silence some warnings in needs_compiler.t

Modified: Module-Build/trunk/t/properties/needs_compiler.t
==============================================================================
--- Module-Build/trunk/t/properties/needs_compiler.t    (original)
+++ Module-Build/trunk/t/properties/needs_compiler.t    Mon Oct 26 20:12:43 2009
@@ -14,9 +14,10 @@
 
 # get a Module::Build object and test with it
 my $mb;
-ok( $mb = $dist->new_from_context, 
-  "Default Build.PL" 
-);
+stderr_of(sub { 
+    ok( $mb = $dist->new_from_context, "Default Build.PL" );
+});
+
 ok( ! $mb->needs_compiler, "needs_compiler is false" );
 ok( ! exists $mb->{properties}{build_requires}{'ExtUtils::CBuilder'},
   "ExtUtils::CBuilder is not in build_requires" 
@@ -31,9 +32,11 @@
     c_source => 'src',
 });
 $dist->regen;
-ok( $mb = $dist->new_from_context, 
-  "Build.PL with c_source" 
-);
+stderr_of(sub { 
+  ok( $mb = $dist->new_from_context, 
+    "Build.PL with c_source" 
+  );
+});
 is( $mb->c_source, 'src', "c_source is set" );
 ok( $mb->needs_compiler, "needs_compiler is true" );
 ok( exists $mb->{properties}{build_requires}{'ExtUtils::CBuilder'},
@@ -47,9 +50,11 @@
 $dist->regen;
 $dist->chdir_in;
 
-ok( $mb = $dist->new_from_context, 
-  "Build.PL with xs files" 
-);
+stderr_of(sub { 
+  ok( $mb = $dist->new_from_context, 
+    "Build.PL with xs files" 
+  );
+});
 ok( $mb->needs_compiler, "needs_compiler is true" );
 ok( exists $mb->{properties}{build_requires}{'ExtUtils::CBuilder'},
   "ExtUtils::CBuilder was added to build_requires" 
@@ -66,9 +71,11 @@
 });
 $dist->regen;
 
-ok( $mb = $dist->new_from_context ,
-  "Build.PL with xs files, but needs_compiler => 0" 
-);
+stderr_of(sub { 
+  ok( $mb = $dist->new_from_context ,
+    "Build.PL with xs files, but needs_compiler => 0" 
+  );
+});
 is( $mb->needs_compiler, 0, "needs_compiler is false" );
 ok( ! exists $mb->{properties}{build_requires}{'ExtUtils::CBuilder'}, 
   "ExtUtils::CBuilder is not in build_requires" 
@@ -85,9 +92,11 @@
 });
 $dist->regen;
 
-ok( $mb = $dist->new_from_context ,
-  "Build.PL with xs files, build_requires EU::CB 0.2"
-);
+stderr_of(sub { 
+  ok( $mb = $dist->new_from_context ,
+    "Build.PL with xs files, build_requires EU::CB 0.2"
+  );
+});
 ok( $mb->needs_compiler, "needs_compiler is true" );
 is( $mb->build_requires->{'ExtUtils::CBuilder'}, 0.2,
   "build_requires for ExtUtils::CBuilder is correct version" 

Reply via email to