blib/lib/Alice/Tabset.pm | |||
---|---|---|---|
Criterion | Covered | Total | % |
statement | 6 | 10 | 60.0 |
branch | n/a | ||
condition | n/a | ||
subroutine | 2 | 4 | 50.0 |
pod | 0 | 1 | 0.0 |
total | 8 | 15 | 53.3 |
line | stmt | bran | cond | sub | pod | time | code |
---|---|---|---|---|---|---|---|
1 | package Alice::Tabset; | ||||||
2 | |||||||
3 | 2 | 2 | 12 | use Any::Moose; | |||
2 | 5 | ||||||
2 | 22 | ||||||
4 | |||||||
5 | 2 | 2 | 1108 | use List::MoreUtils qw/any/; | |||
2 | 4 | ||||||
2 | 365 | ||||||
6 | |||||||
7 | has name => ( | ||||||
8 | is => 'ro', | ||||||
9 | required => 1, | ||||||
10 | ); | ||||||
11 | |||||||
12 | has windows => ( | ||||||
13 | is => 'ro', | ||||||
14 | isa => 'ArrayRef', | ||||||
15 | default => sub {[]}, | ||||||
16 | ); | ||||||
17 | |||||||
18 | sub includes { | ||||||
19 | 0 | 0 | 0 | my ($self, $window_id) = @_; | |||
20 | 0 | 0 | return any {$_ eq $window_id} @{$self->windows}; | ||||
0 | |||||||
0 | |||||||
21 | } | ||||||
22 | |||||||
23 | __PACKAGE__->meta->make_immutable; | ||||||
24 | 1; |