summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorGuillem Jover <guillem@debian.org>2013-06-19 21:14:11 +0200
committerGuillem Jover <guillem@debian.org>2013-06-22 05:30:42 +0200
commite2ea33bdd06c4b5e1f2dfdc624e370086ea2e7bc (patch)
treeba764065f6d6759969af638c8bba9109431a5b06 /test
parentce9c2569c2732db7d9c8940a812f2f07bb57e278 (diff)
downloaddpkg-e2ea33bdd06c4b5e1f2dfdc624e370086ea2e7bc.tar.gz
test: Only scan perl module files that will ever contain POD markup
This should reduce the check time significantly, as it stops checking the program files by duplicate (for <script> and <script>.pl), and does not scan the .git directory any longer.
Diffstat (limited to 'test')
-rw-r--r--test/000_pod.t12
1 files changed, 10 insertions, 2 deletions
diff --git a/test/000_pod.t b/test/000_pod.t
index 40032779e..902a793de 100644
--- a/test/000_pod.t
+++ b/test/000_pod.t
@@ -20,5 +20,13 @@ use Test::More;
eval 'use Test::Pod 1.00';
plan skip_all => 'Test::Pod 1.00 required for testing POD' if $@;
-my @poddirs = ( $ENV{srcdir} || '.' );
-all_pod_files_ok( all_pod_files( @poddirs ) );
+
+if (defined $ENV{srcdir}) {
+ chdir $ENV{srcdir} or die "cannot chdir to source directory: $!";
+}
+
+my @dirs = qw(scripts/Dpkg);
+my @files = qw(scripts/Dpkg.pm);
+push @files, all_pod_files(@dirs);
+
+all_pod_files_ok(@files);