use strict; use warnings; use Test::More tests => 6; use XML::LibXSLT; use XML::LibXML; my $parser = XML::LibXML->new(); # TEST ok($parser, ' TODO : Add test name'); my $doc = $parser->parse_string(<<'EOT'); 1 or 2 Cranky 1 (sort of) Aloof (see Llama) Friendly EOT # TEST ok($doc, ' TODO : Add test name'); my $xslt = XML::LibXSLT->new(); my $style_doc = $parser->parse_string(<<'EOT'); Know Your Dromedaries
Species No of Humps Disposition
EOT # TEST ok($style_doc, ' TODO : Add test name'); # warn "Style_doc = \n", $style_doc->toString, "\n"; my $stylesheet = $xslt->parse_stylesheet($style_doc); # TEST ok($stylesheet, ' TODO : Add test name'); my $results = $stylesheet->transform($doc); # TEST ok($results, ' TODO : Add test name'); my $output = $stylesheet->output_string($results); # TEST ok($output, ' TODO : Add test name'); # warn "Results:\n", $output, "\n";