File: encod03.t

package info (click to toggle)
perl 5.20.2-3%2Bdeb8u11
  • links: PTS, VCS
  • area: main
  • in suites: jessie
  • size: 102,964 kB
  • sloc: perl: 555,553; ansic: 214,041; sh: 38,121; pascal: 8,783; cpp: 3,895; makefile: 2,393; xml: 2,325; yacc: 1,741
file content (77 lines) | stat: -rw-r--r-- 1,249 bytes parent folder | download | duplicates (12)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
# encoding not error 0
BEGIN {
    if($ENV{PERL_CORE}) {
        chdir 't';
        @INC = '../lib';
    }
}

use strict;
use Test;
BEGIN { plan tests => 4 };

#use Pod::Simple::Debug (5);

ok 1;

use Pod::Simple::DumpAsXML;
use Pod::Simple::XMLOutStream;
print "# Pod::Simple version $Pod::Simple::VERSION\n";

{
my @output_lines = split m/[\cm\cj]+/, Pod::Simple::XMLOutStream->_out( q{

=encoding koi8-r

=head1 NAME

Bippitty Boppity Boo -- Yormp

=cut

} );


if(grep m/Unknown directive/i, @output_lines ) {
  ok 0;
  print "# I saw an Unknown directive warning here! :\n",
    map("#==> $_\n", @output_lines), "#\n#\n";
} else {
  ok 1;
}

}

# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
print "# Now a control group, to make sure that =fishbladder DOES\n",
      "#  cause an 'unknown directive' error...\n";
      
{
my @output_lines = split m/[\cm\cj]+/, Pod::Simple::XMLOutStream->_out( q{

=fishbladder

=head1 NAME

Fet's "When you were reading"

=cut

} );


if(grep m/Unknown directive/i, @output_lines ) {
  ok 1;
} else {
  ok 0;
  print "# But I didn't see an Unknows directive warning here! :\n",
    map("#==> $_\n", @output_lines), "#\n#\n";
}

}



print "#\n# And one for the road...\n";
ok 1;