| 1 | package WWW::Asana::Story; | ||||||||||||||||||||||||||||
| 2 | 1 | ▶ | BEGIN { | ||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 3 | 1 | $WWW::Asana::Story::AUTHORITY = 'cpan:GETTY'; | |||||||||||||||||||||||||||
| 4 | } | ||||||||||||||||||||||||||||
| 5 | { | ||||||||||||||||||||||||||||
| 6 | 1 | $WWW::Asana::Story::VERSION = '0.003'; | |||||||||||||||||||||||||||
| 7 | } | ||||||||||||||||||||||||||||
| 8 | # ABSTRACT: Asana Story Class | ||||||||||||||||||||||||||||
| 9 | |||||||||||||||||||||||||||||
| 10 | 1 | ▶ | use MooX; | ||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 11 | |||||||||||||||||||||||||||||
| 12 | 1 | with 'WWW::Asana::Role::HasClient'; | |||||||||||||||||||||||||||
| 13 | 1 | with 'WWW::Asana::Role::HasResponse'; | |||||||||||||||||||||||||||
| 14 | 1 | with 'WWW::Asana::Role::NewFromResponse'; | |||||||||||||||||||||||||||
| 15 | |||||||||||||||||||||||||||||
| 16 | 1 | with 'WWW::Asana::Role::CanReload'; | |||||||||||||||||||||||||||
| 17 | |||||||||||||||||||||||||||||
| 18 | 0 | ▶ | sub own_base_args { 'tags', shift->id } | ||||||||||||||||||||||||||
|
Subroutine
own_base_args: not called CC=1 SCAR=6.9
Pod
undocumented
| |||||||||||||||||||||||||||||
| 19 | |||||||||||||||||||||||||||||
| 20 | 0 | ▶ | sub reload_base_args { 'Tag', 'GET' } | ||||||||||||||||||||||||||
|
Subroutine
reload_base_args: not called CC=1 SCAR=6.9
Pod
undocumented
| |||||||||||||||||||||||||||||
| 21 | |||||||||||||||||||||||||||||
| 22 | 1 | has id => ( | |||||||||||||||||||||||||||
| 23 | is => 'ro', | ||||||||||||||||||||||||||||
| 24 | predicate => 1, | ||||||||||||||||||||||||||||
| 25 | ); | ||||||||||||||||||||||||||||
| 26 | |||||||||||||||||||||||||||||
| 27 | 1 | has text => ( | |||||||||||||||||||||||||||
| 28 | is => 'ro', | ||||||||||||||||||||||||||||
| 29 | predicate => 1, | ||||||||||||||||||||||||||||
| 30 | ); | ||||||||||||||||||||||||||||
| 31 | |||||||||||||||||||||||||||||
| 32 | has type => ( | ||||||||||||||||||||||||||||
| 33 | is => 'ro', | ||||||||||||||||||||||||||||
| 34 | 0 | ▶ | isa => sub { | ||||||||||||||||||||||||||
|
Subroutine
__ANON__: not called CC=2 SCAR=17.9
| |||||||||||||||||||||||||||||
| 35 | 0 | ▶ | die "type must be 'comment' or 'system'" unless grep { $_[0] eq $_ } qw( comment system ); | ||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||
| 36 | }, | ||||||||||||||||||||||||||||
| 37 | 1 | predicate => 1, | |||||||||||||||||||||||||||
| 38 | ); | ||||||||||||||||||||||||||||
| 39 | |||||||||||||||||||||||||||||
| 40 | has source => ( | ||||||||||||||||||||||||||||
| 41 | is => 'ro', | ||||||||||||||||||||||||||||
| 42 | 0 | ▶ | isa => sub { | ||||||||||||||||||||||||||
|
Subroutine
__ANON__: not called CC=2 SCAR=17.9
| |||||||||||||||||||||||||||||
| 43 | die "source must be web, email, mobile, api or unknown" | ||||||||||||||||||||||||||||
| 44 | 0 | ▶ | unless grep { $_[0] eq $_ } qw( web email mobile api unknown ); | ||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||
| 45 | }, | ||||||||||||||||||||||||||||
| 46 | 1 | predicate => 1, | |||||||||||||||||||||||||||
| 47 | ); | ||||||||||||||||||||||||||||
| 48 | |||||||||||||||||||||||||||||
| 49 | has target => ( | ||||||||||||||||||||||||||||
| 50 | is => 'ro', | ||||||||||||||||||||||||||||
| 51 | 0 | ▶ | isa => sub { | ||||||||||||||||||||||||||
|
Subroutine
__ANON__: not called CC=3 SCAR=24.8
| |||||||||||||||||||||||||||||
| 52 | 0 | ▶ | die "target must be a WWW::Asana::Task or WWW::Asana::Project" | ||||||||||||||||||||||||||
|
Branch: 1 branch
Condition0%0/3
ref $_[0] eq "WWW::Asana::Task" or ref $_[0] eq "WWW::Asana::Project"
MC/DC0%0/2
ref $_[0] eq "WWW::Asana::Task" or ref $_[0] eq "WWW::Asana::Project"
ref $_[0] eq "WWW::Asana::Task"
ref $_[0] eq "WWW::Asana::Project"
Truth table0%0/3
A or B
A= ref $_[0] eq "WWW::Asana::Task"B= ref $_[0] eq "WWW::Asana::Project"
| |||||||||||||||||||||||||||||
| 53 | unless ref $_[0] eq 'WWW::Asana::Task' or ref $_[0] eq 'WWW::Asana::Project'; | ||||||||||||||||||||||||||||
| 54 | }, | ||||||||||||||||||||||||||||
| 55 | 1 | required => 1, | |||||||||||||||||||||||||||
| 56 | ); | ||||||||||||||||||||||||||||
| 57 | |||||||||||||||||||||||||||||
| 58 | has created_by => ( | ||||||||||||||||||||||||||||
| 59 | is => 'ro', | ||||||||||||||||||||||||||||
| 60 | 0 | ▶ | isa => sub { | ||||||||||||||||||||||||||
|
Subroutine
__ANON__: not called CC=2 SCAR=17.9
| |||||||||||||||||||||||||||||
| 61 | 0 | ▶ | die "created_by must be a WWW::Asana::User" unless ref $_[0] eq 'WWW::Asana::User'; | ||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||
| 62 | }, | ||||||||||||||||||||||||||||
| 63 | 1 | predicate => 1, | |||||||||||||||||||||||||||
| 64 | ); | ||||||||||||||||||||||||||||
| 65 | |||||||||||||||||||||||||||||
| 66 | has created_at => ( | ||||||||||||||||||||||||||||
| 67 | is => 'ro', | ||||||||||||||||||||||||||||
| 68 | 0 | ▶ | isa => sub { | ||||||||||||||||||||||||||
|
Subroutine
__ANON__: not called CC=2 SCAR=17.9
| |||||||||||||||||||||||||||||
| 69 | 0 | ▶ | die "created_at must be a DateTime" unless ref $_[0] eq 'DateTime'; | ||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||
| 70 | }, | ||||||||||||||||||||||||||||
| 71 | 1 | predicate => 1, | |||||||||||||||||||||||||||
| 72 | ); | ||||||||||||||||||||||||||||
| 73 | |||||||||||||||||||||||||||||
| 74 | 1 | 1; | |||||||||||||||||||||||||||
| 75 | |||||||||||||||||||||||||||||
| 76 | __END__ | ||||||||||||||||||||||||||||