]> git.imager.perl.org - imager.git/blobdiff - t/t82inline.t
test that Parse::RecDescent is loadable to avoid problems like
[imager.git] / t / t82inline.t
index 55b44494ba08324a3b73abee8e8660d1d7e9e5e2..da61334c70110dac299b3985ea61bfc7cb438100 100644 (file)
@@ -6,13 +6,20 @@ use Test::More;
 eval "require Inline::C;";
 plan skip_all => "Inline required for testing API" if $@;
 
+eval "require Parse::RecDescent;";
+plan skip_all => "Could not load Parse::RecDescent" if $@;
+
 use Cwd 'getcwd';
 plan skip_all => "Inline won't work in directories with spaces"
   if getcwd() =~ / /;
 
+plan skip_all => "perl 5.005_04, 5.005_05 too buggy"
+  if $] =~ /^5\.005_0[45]$/;
+
 plan tests => 9;
 require Inline;
 Inline->import(with => 'Imager');
+Inline->import("FORCE"); # force rebuild
 
 Inline->bind(C => <<'EOS');
 #include <math.h>
@@ -251,7 +258,7 @@ ok($im3->write(file=>'testout/t82lots.ppm'), "write t82lots.ppm");
 
   my $im = make_10x10();
   my $im2 = Imager->new(xsize => 10, ysize => 10);
-  use B;
+  require B;
   my $imb = B::svref_2object($im);
   my $im2b = B::svref_2object($im2);
   is ($imb->REFCNT, $im2b->REFCNT,