Dave Rolsky wrote:
On Tue, 10 Jun 2008, Eric Roode wrote:
How do you do that, by the way? How do you set it up so the test
suite knows it's you and not an end-user?
plan skip_all => 'This test is only run for the module author'
unless -d '.svn' || $ENV{IS_MAINTAINER};
Perl::Critic used to do that sort of thing, but no more. Too many times people
would grab from the public repository or have the same environment variable set
and the author tests would run and we'd get failure reports. Now, in order to
run author tests you actually have to specifically invoke a Module::Build
target to get them to run:
sub ACTION_authortest {
my ($self) = @_;
$self->depends_on('build');
$self->depends_on('manifest');
$self->depends_on('distmeta');
$self->test_files( qw< t xt/author > );
$self->recursive_test_files(1);
$self->depends_on('test');
return;
}
http://search.cpan.org/src/ELLIOTJS/Perl-Critic-1.085/Build.PL