diff options
-rw-r--r-- | Changes | 1 | ||||
-rw-r--r-- | MANIFEST | 1 | ||||
-rw-r--r-- | Makefile.PL | 11 | ||||
-rw-r--r-- | t/pod.t | 47 |
4 files changed, 60 insertions, 0 deletions
@@ -1,5 +1,6 @@ libnet 1.28 -- TODO + * Add optional POD testing. * Make code Perl::Critic clean. * Move Net/*.pm into lib/Net/ sub-directory within distribution. This is the usual layout style these days. @@ -34,6 +34,7 @@ t/hostname.t t/libnet_t.pl t/netrc.t t/nntp.t +t/pod.t t/require.t t/smtp.t t/smtp_ssl.t diff --git a/Makefile.PL b/Makefile.PL index fe35c56..a110530 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -115,6 +115,17 @@ MAIN: { } } } + }, + + podtest => { + description => 'POD testing', + prereqs => { + test => { + requires => { + 'Test::Pod' => '1.00' + } + } + } } } }, @@ -0,0 +1,47 @@ +#!perl
+#===============================================================================
+#
+# t/pod.t
+#
+# DESCRIPTION
+# Test script to check POD.
+#
+# COPYRIGHT
+# Copyright (C) 2014 Steve Hay. All rights reserved.
+#
+# LICENCE
+# You may distribute under the terms of either the GNU General Public License
+# or the Artistic License, as specified in the LICENCE file.
+#
+#===============================================================================
+
+use 5.008001;
+
+use strict;
+use warnings;
+
+use Test::More;
+
+#===============================================================================
+# MAIN PROGRAM
+#===============================================================================
+
+MAIN: {
+ my $ok = eval {
+ require Test::Pod;
+ Test::Pod->import();
+ 1;
+ };
+
+ if (not $ok) {
+ plan skip_all => 'Test::Pod required to test POD';
+ }
+ elsif ($Test::Pod::VERSION < 1.00) {
+ plan skip_all => 'Test::Pod 1.00 or higher required to test POD';
+ }
+ else {
+ all_pod_files_ok();
+ }
+}
+
+#===============================================================================
|