From: Graham Knop Date: Tue, 23 Aug 2016 09:46:48 +0000 (-0400) Subject: don't dupe xt tests if already specified X-Git-Tag: v0.003000~25 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=4762e03a604a8fa741c10232f7f60eb31fdd735a;p=p5sagit%2FDistar.git don't dupe xt tests if already specified --- diff --git a/lib/Distar.pm b/lib/Distar.pm index 4682e04..88adffd 100644 --- a/lib/Distar.pm +++ b/lib/Distar.pm @@ -77,13 +77,18 @@ sub write_manifest_skip { sub new { my ($class, $args) = @_; + my %test = %{$args->{test}||{}}; + my $tests = $test{TESTS} || 't/*.t'; + $tests !~ /\b\Q$_\E\b/ and $tests .= " $_" + for 'xt/*.t', 'xt/*/*.t'; + $test{TESTS} = $tests; return $class->SUPER::new({ LICENSE => 'perl_5', MIN_PERL_VERSION => '5.006', AUTHOR => ($MM_VER >= 6.5702 ? $Distar::Author : join(', ', @$Distar::Author)), (exists $args->{ABSTRACT} ? () : (ABSTRACT_FROM => $args->{VERSION_FROM})), %$args, - test => { TESTS => ($args->{test}{TESTS}||'t/*.t').' xt/*.t xt/*/*.t' }, + test => \%test, realclean => { FILES => ( ($args->{realclean}{FILES}||'') . ' Distar/ MANIFEST.SKIP MANIFEST MANIFEST.bak'