1N/A#!./perl
1N/A
1N/ABEGIN { chdir 't' if -d 't'; @INC = '../lib' }
1N/A
1N/Ause Pod::Plainer;
1N/Amy $parser = Pod::Plainer->new();
1N/Amy $header = "=pod\n\n";
1N/Amy $input = 'plnr_in.pod';
1N/Amy $output = 'plnr_out.pod';
1N/A
1N/Amy $test = 0;
1N/Aprint "1..7\n";
1N/Awhile( <DATA> ) {
1N/A my $expected = $header.<DATA>;
1N/A
1N/A open(IN, '>', $input) or die $!;
1N/A print IN $header, $_;
1N/A close IN or die $!;
1N/A
1N/A open IN, '<', $input or die $!;
1N/A open OUT, '>', $output or die $!;
1N/A $parser->parse_from_filehandle(\*IN,\*OUT);
1N/A
1N/A open OUT, '<', $output or die $!;
1N/A my $returned; { local $/; $returned = <OUT>; }
1N/A
1N/A unless( $returned eq $expected ) {
1N/A print map { s/^/\#/mg; $_; }
1N/A map {+$_} # to avoid readonly values
1N/A "EXPECTED:\n", $expected, "GOT:\n", $returned;
1N/A print "not ";
1N/A }
1N/A printf "ok %d\n", ++$test;
1N/A close OUT;
1N/A close IN;
1N/A}
1N/A
1N/AEND {
1N/A 1 while unlink $input;
1N/A 1 while unlink $output;
1N/A}
1N/A
1N/A__END__
1N/A=head <> now reads in records
1N/A=head E<lt>E<gt> now reads in records
1N/A=item C<-T> and C<-B> not implemented on filehandles
1N/A=item C<-T> and C<-B> not implemented on filehandles
1N/Ae.g. C<< Foo->bar() >> or C<< $obj->bar() >>
1N/Ae.g. C<Foo-E<gt>bar()> or C<$obj-E<gt>bar()>
1N/AThe C<< => >> operator is mostly just a more visually distinctive
1N/AThe C<=E<gt>> operator is mostly just a more visually distinctive
1N/AC<uv < 0x80> in which case you can use C<*s = uv>.
1N/AC<uv E<lt> 0x80> in which case you can use C<*s = uv>.
1N/AC<time ^ ($$ + ($$ << 15))>), but that isn't necessary any more.
1N/AC<time ^ ($$ + ($$ E<lt>E<lt> 15))>), but that isn't necessary any more.
1N/AThe bitwise operation C<<< >> >>>
1N/AThe bitwise operation C<E<gt>E<gt>>