3 use Test::More tests => 6;
11 use_ok('Debbugs::Status');
13 my $data = {package => 'foo, bar, baz',
16 tags => 'foo bar baz',
19 my @temp = Debbugs::Status::split_status_fields($data);
20 is_deeply($temp[0]{package},[qw(foo bar baz)],
21 'split_status_fields splits packages properly',
23 is_deeply($temp[0]{blocks},[qw(1 2 3)],
24 'split_status_fields splits blocks properly',
26 is_deeply($temp[0]{blockedby},[],
27 'split_status_fields handles empty fields properly',
29 is_deeply($temp[0]{tags},[qw(foo bar baz)],
30 'split_status_fields splits tags properly',
32 my $temp = Debbugs::Status::split_status_fields($data);
33 is_deeply(Debbugs::Status::split_status_fields($temp),$temp,
34 'recursively calling split_status_fields returns the same thing');