X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2Fpod%2Ftestp2pt.pl;h=bec55e45b4523a7f29e404837d72322eb3bec722;hb=9c6ed6d7263c1b2c230f35c31c8bcd2eef2d5431;hp=4d99f82a72e829d0d6689682d7ee702dd237cb5f;hpb=be708cc0141c68546a70e3d19f68ad41bef15add;p=p5sagit%2Fp5-mst-13.2.git diff --git a/t/pod/testp2pt.pl b/t/pod/testp2pt.pl index 4d99f82..bec55e4 100644 --- a/t/pod/testp2pt.pl +++ b/t/pod/testp2pt.pl @@ -24,14 +24,8 @@ use vars qw($MYPKG @EXPORT @ISA); $MYPKG = eval { (caller)[0] }; @EXPORT = qw(&testpodplaintext); BEGIN { - if ( $] >= 5.005_58 ) { - require Pod::Text; - @ISA = qw( Pod::Text ); - } - else { - require Pod::PlainText; - @ISA = qw( Pod::PlainText ); - } + require Pod::PlainText; + @ISA = qw( Pod::PlainText ); require VMS::Filespec if $^O eq 'VMS'; } @@ -42,21 +36,15 @@ BEGIN { sub catfile(@) { File::Spec->catfile(@_); } my $INSTDIR = abs_path(dirname $0); -if ($^O eq 'VMS') { # clean up directory spec - $INSTDIR = VMS::Filespec::unixpath($INSTDIR); - $INSTDIR =~ s#/$##; - $INSTDIR =~ s#/000000/#/#; -} -# cut 't/pod' from path (cut 't:pod:' on Mac OS) +$INSTDIR = VMS::Filespec::unixpath($INSTDIR) if $^O eq 'VMS'; +$INSTDIR =~ s#/$## if $^O eq 'VMS'; $INSTDIR = (dirname $INSTDIR) if (basename($INSTDIR) eq 'pod'); $INSTDIR = (dirname $INSTDIR) if (basename($INSTDIR) eq 't'); - my @PODINCDIRS = ( catfile($INSTDIR, 'lib', 'Pod'), catfile($INSTDIR, 'scripts'), catfile($INSTDIR, 'pod'), catfile($INSTDIR, 't', 'pod') ); -print "PODINCDIRS = ",join(', ',@PODINCDIRS),"\n"; ## Find the path to the file to =include sub findinclude { @@ -112,7 +100,7 @@ sub begin_input { sub podinc2plaintext( $ $ ) { my ($infile, $outfile) = @_; local $_; - my $text_parser = $MYPKG->new(quotes => "`'"); + my $text_parser = $MYPKG->new; $text_parser->parse_from_file($infile, $outfile); } @@ -158,7 +146,7 @@ sub testpodplaintext( @ ) { for $podfile (@testpods) { ($testname, $_) = fileparse($podfile); $testdir ||= $_; - $testname =~ s/\..*$//; + $testname =~ s/\.t$//; $cmpfile = $testdir . $testname . '.xr'; $outfile = $testdir . $testname . '.OUT';