AnyMQ-AMQP
view release on metacpan or search on metacpan
inc/Module/Install/ExtraTests.pm view on Meta::CPAN
return;
}
{
no warnings qw(once);
package # The newline tells PAUSE, "DO NOT INDEXING!"
MY;
sub test_via_harness {
my $self = shift;
return $self->SUPER::test_via_harness(@_)
unless $use_extratests;
my ($perl, $tests) = @_;
my $a_str = -d 'xt/author' ? 'xt/author' : '';
my $r_str = -d 'xt/release' ? 'xt/release' : '';
my $s_str = -d 'xt/smoke' ? 'xt/smoke' : '';
my $is_author = $Module::Install::AUTHOR ? 1 : 0;
return qq{\t$perl "-Iinc" "-MModule::Install::ExtraTests" }
. qq{"-e" "Module::Install::ExtraTests::__harness('Test::Harness', $is_author, '$a_str', '$r_str', '$s_str', \$(TEST_VERBOSE), '\$(INST_LIB)', '\$(INST_ARCHLIB)')" $tests\n};
}
sub dist_test {
my ($self, @args) = @_;
return $self->SUPER::dist_test(@args)
unless $use_extratests;
my $text = $self->SUPER::dist_test(@args);
my @lines = split /\n/, $text;
$_ =~ s/ (\S*MAKE\S* test )/ RELEASE_TESTING=1 $1 / for grep { m/ test / } @lines;
return join "\n", @lines;
}
}
sub __harness {
my $harness_class = shift;
my $is_author = shift;
my $author_tests = shift;
( run in 1.269 second using v1.01-cache-2.11-cpan-49f99fa48dc )