line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Test::Stream::Event; |
2
|
107
|
|
|
107
|
|
770
|
use strict; |
|
107
|
|
|
|
|
107
|
|
|
107
|
|
|
|
|
2480
|
|
3
|
107
|
|
|
107
|
|
294
|
use warnings; |
|
107
|
|
|
|
|
102
|
|
|
107
|
|
|
|
|
2146
|
|
4
|
|
|
|
|
|
|
|
5
|
107
|
|
|
107
|
|
314
|
use Carp qw/confess carp/; |
|
107
|
|
|
|
|
119
|
|
|
107
|
|
|
|
|
4824
|
|
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
use Test::Stream::HashBase( |
8
|
107
|
|
|
|
|
654
|
accessors => [qw/debug nested/], |
9
|
107
|
|
|
107
|
|
406
|
); |
|
107
|
|
|
|
|
132
|
|
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
sub import { |
12
|
9
|
|
|
9
|
|
331
|
my $class = shift; |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
# Import should only when event is imported, subclasses do not use this |
15
|
|
|
|
|
|
|
# import. |
16
|
9
|
50
|
|
|
|
3248
|
return if $class ne __PACKAGE__; |
17
|
|
|
|
|
|
|
|
18
|
0
|
|
|
|
|
0
|
carp "The magical 'import' method on $class is deprecated and will be removed in the near future."; |
19
|
|
|
|
|
|
|
|
20
|
0
|
|
|
|
|
0
|
my $caller = caller; |
21
|
0
|
|
|
|
|
0
|
my (%args) = @_; |
22
|
|
|
|
|
|
|
|
23
|
0
|
|
0
|
|
|
0
|
my $accessors = $args{accessors} || []; |
24
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
# %args may override base |
26
|
0
|
|
|
|
|
0
|
Test::Stream::HashBase->import(into => $caller, base => $class, %args); |
27
|
|
|
|
|
|
|
} |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
sub init { |
30
|
544
|
100
|
|
544
|
0
|
2090
|
confess("No debug info provided!") unless $_[0]->{+DEBUG}; |
31
|
|
|
|
|
|
|
} |
32
|
|
|
|
|
|
|
|
33
|
3
|
|
|
3
|
1
|
15
|
sub causes_fail { 0 } |
34
|
|
|
|
|
|
|
|
35
|
1
|
|
|
1
|
1
|
12
|
sub to_tap {()}; |
36
|
49
|
|
|
49
|
1
|
73
|
sub update_state {()}; |
37
|
3267
|
|
|
3267
|
1
|
4822
|
sub terminate {()}; |
38
|
3187
|
|
|
3187
|
1
|
6239
|
sub global {()}; |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
1; |
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
__END__ |