6f594b97b603ae4731c8bde4dad92e9f63bcc5e9
[dh-make-perl] / dev / arm / libhtml-parser-perl / libhtml-parser-perl-3.56 / t / argspec2.t
1 use Test::More tests => 2;
2
3 use strict;
4 use HTML::Parser;
5
6 my @start;
7 my @text;
8
9 my $p = HTML::Parser->new(api_version => 3);
10 $p->handler(start => \@start, '@{tagname, @attr}');
11 $p->handler(text  => \@text,  '@{dtext}');
12 $p->parse(<<EOT)->eof;
13 Hi
14 <a href="abc">Foo</a><b>:-)</b>
15 EOT
16
17 is("@start", "a href abc b");
18
19 is(join("", @text), "Hi\nFoo:-)\n");
20
21