# Stolen from Mac::PropertyList (by comdog) for use in Mac::PropertyList::SAX (by kulp) use Test::More tests => 5; use Mac::PropertyList::SAX; ######################################################################## # Test the array bits { my $array = Mac::PropertyList::array->new(); isa_ok( $array, "Mac::PropertyList::array", 'Make empty object' ); is( $array->count, 0, 'Empty object has no elements' ); } my $array =<<"HERE"; Mimi Roscoe Juliet Buster HERE $plist = Mac::PropertyList::SAX::parse_plist( $array ); isa_ok( $plist, "Mac::PropertyList::array", "Make object from plist string" ); is( $plist->count, 4, "Object has right number of values" ); my @values = $plist->values; ok( eq_array( \@values, [qw(Mimi Roscoe Juliet Buster)] ), "Object has right values" );