1 use Test::More tests => 2;
9 $res .= "[" . join("\n", map "<$_>", @$t) . "]";
17 my $p = HTML::Parser->new(declaration_h => [\&decl, "tokens"],
18 default_h => [\&text, "text"],
21 $p->parse(<<EOT)->eof;
22 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" --<comment>--
23 "http://www.w3.org/TR/html40/strict.dtd">
25 <!ENTITY foo "<!-- foo -->">
26 <!Entity foo "<!-- foo -->">
35 <"-//W3C//DTD HTML 4.01//EN">
37 <"http://www.w3.org/TR/html40/strict.dtd">]
50 $p->parse(<<EOT)->eof;
51 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
52 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"[]>
58 <"-//W3C//DTD XHTML 1.0 Strict//EN">
59 <"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">