use strict; use warnings; use Test::More tests => 5; # last test to print use XML::XPathScript; my $xps = XML::XPathScript->new; my $result = $xps->transform( 'hello', 'fluff' ); is $result => 'fluff', '$xps->transform()'; $result = $xps->transform( 'hello', '<%~ /doc/t %>' ); is $result => 'hello' ; # same stylesheet, different xml $result = $xps->transform( 'world!', undef ); is $result => 'world!' ; # same stylesheet, different xml $result = $xps->transform( 'foo' ); is $result => 'foo' ; # same xml document, different stylesheet $result = $xps->transform( undef, '<%~ / %>' ); is $result => 'foo' ;