$^O eq 'MSWin32'
? plan(skip_all => "ActiveState perl produces additional warnings, and this test uses unix paths")
- : plan(tests => 143);
+ : plan(tests => 145);
my $DUMP_PATH = './t/_dump';
sub dump_dbicdump {
my %tdata = @_;
- my @cmd = qw(./script/dbicdump);
+ # use $^X so we execute ./script/dbicdump with the same perl binary that the tests were executed with
+ my @cmd = ($^X, qw(./script/dbicdump));
while (my ($opt, $val) = each(%{ $tdata{options} })) {
push @cmd, '-o', "$opt=$val";
push @cmd, $tdata{classname}, $make_dbictest_db::dsn;
+ # make sure our current @INC gets used by dbicdump
+ local $ENV{PERL5LIB} = join ":", @INC, $ENV{PERL5LIB};
+
my ($in, $out, $err);
my $pid = open3($in, $out, $err, @cmd);