Subject: | tests use perl from PATH instead of $^X |
If the perl in your PATH is different from the perl you're using to
build the module, the tests fail.
--- t/00.createapp.t.orig 2007-11-09 02:03:31.000000000 -0800
+++ t/00.createapp.t 2007-11-09 02:04:19.000000000 -0800
@@ -17,12 +17,12 @@
my $tmpdir = dir(qw/ t tmp/);
my $libdir = dir(dir()->parent->parent, 'lib');
my $instant = file(dir()->parent->parent, 'script', 'instantcrud.pl');
-my $line = "cd $tmpdir; perl -I$libdir ../../script/instantcrud.pl
-name=My::App -dsn='dbi:SQLite:dbname=$testfile' -noauth";
+my $line = "cd $tmpdir; $^X -I$libdir ../../script/instantcrud.pl
-name=My::App -dsn='dbi:SQLite:dbname=$testfile' -noauth";
warn $line;
my $currdir = dir()->absolute;
chdir $tmpdir;
-`perl -I$libdir ../../script/instantcrud.pl -name=My::App
-dsn='dbi:SQLite:dbname=$testfile' -noauth`;
+`$^X -I$libdir ../../script/instantcrud.pl -name=My::App
-dsn='dbi:SQLite:dbname=$testfile' -noauth`;
chdir $currdir;
my $schemafile = file(qw/ t tmp My-App lib My App DBSchema.pm/);
--- t/20.create_dvdzbr.t.orig 2007-11-09 02:03:38.000000000 -0800
+++ t/20.create_dvdzbr.t 2007-11-09 02:04:37.000000000 -0800
@@ -15,7 +15,7 @@
copy $origtestfile, $testfile;
-`cd t/tmp; perl -I../../lib ../../script/instantcrud.pl -name=$app
-dsn='dbi:SQLite:dbname=$testfile'`;
+`cd t/tmp; $^X -I../../lib ../../script/instantcrud.pl -name=$app
-dsn='dbi:SQLite:dbname=$testfile'`;
ok( -f "t/tmp/$app/lib/$app/DBSchema.pm", 'DBSchema creation');
--
Rafael