2 # $Id: text.t,v 1.4 2006-01-20 21:20:58 eagle Exp $
4 # text.t -- Additional specialized tests for Pod::Text.
6 # Copyright 2002, 2004 by Russ Allbery <rra@stanford.edu>
8 # This program is free software; you may redistribute it and/or modify it
9 # under the same terms as Perl itself.
13 if ($ENV{PERL_CORE}) {
16 unshift (@INC, '../blib/lib');
18 unshift (@INC, '../blib/lib');
24 print "not ok 1\n" unless $loaded;
32 my $parser = Pod::Text->new or die "Cannot create parser\n";
35 next until $_ eq "###\n";
36 open (TMP, '> tmp.pod') or die "Cannot create tmp.pod: $!\n";
38 last if $_ eq "###\n";
42 $parser->parse_from_file ('tmp.pod', 'out.tmp');
43 open (TMP, 'out.tmp') or die "Cannot open out.tmp: $!\n";
50 unlink ('tmp.pod', 'out.tmp');
53 last if $_ eq "###\n";
56 if ($output eq $expected) {
60 print "Expected\n========\n$expected\nOutput\n======\n$output\n";
65 # Below the marker are bits of POD and corresponding expected text output.
66 # This is used to test specific features or problems with Pod::Text. The
67 # input and output are separated by lines containing only ###.
74 This C<.> should be quoted.
77 This "." should be quoted.
82 =head1 CE<lt>E<gt> WITH SPACES
84 What does C<< this. >> end up looking like?
87 What does "this." end up looking like?