From c97631728ce7d6d3f4692a56c3cda7476b42a968 Mon Sep 17 00:00:00 2001 From: Lorry Tar Creator Date: Tue, 20 Nov 2007 14:28:05 +0000 Subject: Imported from /home/lorry/working-area/delta_perl-xml-parser/XML-Parser-2.36.tar.gz. --- t/file.t | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 t/file.t (limited to 't/file.t') diff --git a/t/file.t b/t/file.t new file mode 100644 index 0000000..d7c4f53 --- /dev/null +++ b/t/file.t @@ -0,0 +1,15 @@ +BEGIN {print "1..2\n";} +END {print "not ok 1\n" unless $loaded;} +use XML::Parser; +$loaded = 1; +print "ok 1\n"; + +my $count = 0; + +$parser = new XML::Parser(ErrorContext => 2); +$parser->setHandlers(Comment => sub {$count++;}); + +$parser->parsefile('samples/REC-xml-19980210.xml'); + +print "not " unless $count == 37; +print "ok 2\n"; -- cgit v1.2.1