Filename | /home/micha/.plenv/versions/5.38.2/lib/perl5/site_perl/5.38.2/Test/Builder/Formatter.pm |
Statements | Executed 20 statements in 391µs |
Calls | P | F | Exclusive Time |
Inclusive Time |
Subroutine |
---|---|---|---|---|---|
1 | 1 | 1 | 1.78ms | 2.16ms | BEGIN@7 | Test::Builder::Formatter::
1 | 1 | 1 | 18µs | 20µs | BEGIN@11 | Test::Builder::Formatter::
1 | 1 | 1 | 9µs | 11µs | BEGIN@2 | Test::Builder::Formatter::
1 | 1 | 1 | 5µs | 51µs | BEGIN@9 | Test::Builder::Formatter::
1 | 1 | 1 | 5µs | 9µs | plan_tap | Test::Builder::Formatter::
1 | 1 | 1 | 4µs | 20µs | BEGIN@3 | Test::Builder::Formatter::
1 | 1 | 1 | 3µs | 86µs | init | Test::Builder::Formatter::
0 | 0 | 0 | 0s | 0s | __ANON__[:16] | Test::Builder::Formatter::
0 | 0 | 0 | 0s | 0s | debug_tap | Test::Builder::Formatter::
0 | 0 | 0 | 0s | 0s | info_tap | Test::Builder::Formatter::
0 | 0 | 0 | 0s | 0s | no_subtest_space | Test::Builder::Formatter::
0 | 0 | 0 | 0s | 0s | redirect | Test::Builder::Formatter::
Line | State ments |
Time on line |
Calls | Time in subs |
Code |
---|---|---|---|---|---|
1 | package Test::Builder::Formatter; | ||||
2 | 2 | 18µs | 2 | 13µs | # spent 11µs (9+2) within Test::Builder::Formatter::BEGIN@2 which was called:
# once (9µs+2µs) by Test::Builder::BEGIN@36 at line 2 # spent 11µs making 1 call to Test::Builder::Formatter::BEGIN@2
# spent 2µs making 1 call to strict::import |
3 | 2 | 33µs | 2 | 37µs | # spent 20µs (4+17) within Test::Builder::Formatter::BEGIN@3 which was called:
# once (4µs+17µs) by Test::Builder::BEGIN@36 at line 3 # spent 20µs making 1 call to Test::Builder::Formatter::BEGIN@3
# spent 17µs making 1 call to warnings::import |
4 | |||||
5 | 1 | 200ns | our $VERSION = '1.302198'; | ||
6 | |||||
7 | 2 | 80µs | 1 | 2.16ms | # spent 2.16ms (1.78+384µs) within Test::Builder::Formatter::BEGIN@7 which was called:
# once (1.78ms+384µs) by Test::Builder::BEGIN@36 at line 7 # spent 2.16ms making 1 call to Test::Builder::Formatter::BEGIN@7 |
8 | |||||
9 | 2 | 48µs | 2 | 97µs | # spent 51µs (5+46) within Test::Builder::Formatter::BEGIN@9 which was called:
# once (5µs+46µs) by Test::Builder::BEGIN@36 at line 9 # spent 51µs making 1 call to Test::Builder::Formatter::BEGIN@9
# spent 46µs making 1 call to Test2::Util::HashBase::import |
10 | |||||
11 | # spent 20µs (18+2) within Test::Builder::Formatter::BEGIN@11 which was called:
# once (18µs+2µs) by Test::Builder::BEGIN@36 at line 17 | ||||
12 | 1 | 5µs | 1 | 900ns | *OUT_STD = Test2::Formatter::TAP->can('OUT_STD'); # spent 900ns making 1 call to UNIVERSAL::can |
13 | 1 | 7µs | 1 | 500ns | *OUT_ERR = Test2::Formatter::TAP->can('OUT_ERR'); # spent 500ns making 1 call to UNIVERSAL::can |
14 | |||||
15 | 1 | 3µs | 1 | 300ns | my $todo = OUT_ERR() + 1; # spent 300ns making 1 call to Test2::Formatter::TAP::OUT_ERR |
16 | 1 | 5µs | *OUT_TODO = sub() { $todo }; | ||
17 | 1 | 182µs | 1 | 20µs | } # spent 20µs making 1 call to Test::Builder::Formatter::BEGIN@11 |
18 | |||||
19 | # spent 86µs (3+82) within Test::Builder::Formatter::init which was called:
# once (3µs+82µs) by Test2::Util::HashBase::_new at line 155 of Test2/Util/HashBase.pm | ||||
20 | 1 | 100ns | my $self = shift; | ||
21 | 1 | 1µs | 1 | 82µs | $self->SUPER::init(@_); # spent 82µs making 1 call to Test2::Formatter::TAP::init |
22 | 1 | 2µs | $self->{+HANDLES}->[OUT_TODO] = $self->{+HANDLES}->[OUT_STD]; | ||
23 | } | ||||
24 | |||||
25 | # spent 9µs (5+4) within Test::Builder::Formatter::plan_tap which was called:
# once (5µs+4µs) by Test2::Formatter::TAP::event_tap at line 169 of Test2/Formatter/TAP.pm | ||||
26 | 1 | 300ns | my ($self, $f) = @_; | ||
27 | |||||
28 | 1 | 400ns | return if $self->{+NO_HEADER}; | ||
29 | 1 | 4µs | 1 | 4µs | return $self->SUPER::plan_tap($f); # spent 4µs making 1 call to Test2::Formatter::TAP::plan_tap |
30 | } | ||||
31 | |||||
32 | sub debug_tap { | ||||
33 | my ($self, $f, $num) = @_; | ||||
34 | return if $self->{+NO_DIAG}; | ||||
35 | my @out = $self->SUPER::debug_tap($f, $num); | ||||
36 | $self->redirect(\@out) if @out && ref $f->{about} && defined $f->{about}->{package} | ||||
37 | && $f->{about}->{package} eq 'Test::Builder::TodoDiag'; | ||||
38 | return @out; | ||||
39 | } | ||||
40 | |||||
41 | sub info_tap { | ||||
42 | my ($self, $f) = @_; | ||||
43 | return if $self->{+NO_DIAG}; | ||||
44 | my @out = $self->SUPER::info_tap($f); | ||||
45 | $self->redirect(\@out) if @out && ref $f->{about} && defined $f->{about}->{package} | ||||
46 | && $f->{about}->{package} eq 'Test::Builder::TodoDiag'; | ||||
47 | return @out; | ||||
48 | } | ||||
49 | |||||
50 | sub redirect { | ||||
51 | my ($self, $out) = @_; | ||||
52 | $_->[0] = OUT_TODO for @$out; | ||||
53 | } | ||||
54 | |||||
55 | sub no_subtest_space { 1 } | ||||
56 | |||||
57 | 1 | 2µs | 1; | ||
58 | |||||
59 | __END__ |