1use strict; 2use warnings; 3use Test::More tests => 9; 4 5#use Pod::Simple::Debug (2); 6 7BEGIN { 8 require FindBin; 9 unshift @INC, $FindBin::Bin . '/lib'; 10} 11use helpers; 12 13use Pod::Simple::DumpAsXML; 14use Pod::Simple::XMLOutStream; 15print "# Pod::Simple version $Pod::Simple::VERSION\n"; 16 17is( Pod::Simple::XMLOutStream->_out("=head1 =head1"), 18 '<Document><head1>=head1</head1></Document>' 19); 20 21is( Pod::Simple::XMLOutStream->_out("\n=head1 =head1"), 22 '<Document><head1>=head1</head1></Document>' 23); 24 25is( Pod::Simple::XMLOutStream->_out("\n=head1 =head1\n"), 26 '<Document><head1>=head1</head1></Document>' 27); 28 29is( Pod::Simple::XMLOutStream->_out("\n=head1 =head1\n\n"), 30 '<Document><head1>=head1</head1></Document>' 31); 32 33&is(e "\n=head1 =head1\n\n" , "\n=head1 =head1\n\n"); 34 35&is(e "\n=head1\n=head1\n\n", "\n=head1 =head1\n\n"); 36 37&is(e "\n=pod\n\nCha cha cha\n\n" , "\n=pod\n\nCha cha cha\n\n"); 38&is(e "\n=pod\n\nCha\tcha cha\n\n" , "\n=pod\n\nCha cha cha\n\n"); 39&is(e "\n=pod\n\nCha\ncha cha\n\n" , "\n=pod\n\nCha cha cha\n\n"); 40