eval { require B::Hooks::EndOfScope }
or plan skip_all => "PP tests already executed";
-eval { require Devel::Hide }
- or plan skip_all => "Devel::Hide required for this test in presence of B::Hooks::EndOfScope";
+# the PP tests will run either wih D::H (mainly on smokers)
+# or by setting the envvar (for users)
+my $has_d_h = eval { require Devel::Hide };
use Config;
use FindBin qw($Bin);
next if $fn =~ /${this_file}$/;
local $ENV{DEVEL_HIDE_VERBOSE} = 0;
- my @cmd = ( $^X, '-MDevel::Hide=B::Hooks::EndOfScope', $fn );
+ local $ENV{NAMESPACE_CLEAN_USE_PP} = 1 unless $has_d_h;
+ my @cmd = (
+ $^X,
+ $has_d_h ? '-MDevel::Hide=B::Hooks::EndOfScope' : (),
+ $fn
+ );
# this is cheating, and may even hang here and there (testing on windows passed fine)
# if it does - will have to fix it somehow (really *REALLY* don't want to pull