4 |
|
|
5 |
my $debug = @ARGV ? 1 : 0; |
my $debug = @ARGV ? 1 : 0; |
6 |
|
|
7 |
use Test::More tests => 26; |
use Test::More tests => 28; |
8 |
use lib 'lib'; |
use lib 'lib'; |
9 |
|
|
10 |
use Data::Dump qw/dump/; |
use Data::Dump qw/dump/; |
19 |
diag ref( $required ) if $debug; |
diag ref( $required ) if $debug; |
20 |
isa_ok( $required, 'ARRAY', 'required' ); |
isa_ok( $required, 'ARRAY', 'required' ); |
21 |
|
|
22 |
|
ok( $required = $o->required( as_hash => 1 ), 'required as_hash' ); |
23 |
|
diag dump $required; |
24 |
|
isa_ok( $required, 'HASH', 'hash' ); |
25 |
|
|
26 |
ok( my $attributes = $o->attributes, 'attributes' ); |
ok( my $attributes = $o->attributes, 'attributes' ); |
27 |
diag dump( $attributes ) if $debug; |
diag dump( $attributes ) if $debug; |
28 |
is_deeply( $attributes, ["uri", "feed", "title"], 'attributes' ); |
is_deeply( $attributes, ["uri", "feed", "title"], 'attributes' ); |