1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
|
#!perl -T
use Test::More tests => 15; # SEE FOREACH LOOP BLOW
#use Test::More 'no_plan';
use lib 't';
use TestConfig;
login_myspace or die "Login Failed - can't run tests";
my $myspace = $CONFIG->{acct1}->{myspace}; # For sanity
#individual profile
my ( %info ) = $myspace->get_basic_info( $CONFIG->{acct1}->{friend_id} );
#foreach $key ( keys( %info ) ) {
# warn "$key: $info{$key}\n";
#}
# If you change the number of keys here, change the number of tests above.
foreach my $key ( 'country', 'cityregion', 'city', 'region','headline', 'age', 'gender', 'lastlogin' ) {
ok( $info{"$key"}, "individual: get_basic_info $key : $info{\"$key\"}" );
}
#bandprofile
( %info ) = $myspace->get_basic_info( 3327112 );
# If you change the number of keys here, change the number of tests above.
foreach my $key ( 'country', 'cityregion', 'city', 'region','headline','profileviews', 'lastlogin' ) {
ok( $info{"$key"}, "band: get_basic_info $key : $info{\"$key\"}" );
}
|