← Index
NYTProf Performance Profile   « line view »
For t/bug-md-11.t
  Run on Fri Mar 8 13:27:24 2024
Reported on Fri Mar 8 13:30:23 2024

Filename/home/micha/.plenv/versions/5.38.2/lib/perl5/site_perl/5.38.2/Test2/Event/Pass.pm
StatementsExecuted 13 statements in 287µs
Subroutines
Calls P F Exclusive
Time
Inclusive
Time
Subroutine
11123µs23µsTest2::Event::Pass::::BEGIN@7Test2::Event::Pass::BEGIN@7
11111µs12µsTest2::Event::Pass::::BEGIN@2Test2::Event::Pass::BEGIN@2
1118µs8µsTest2::Event::Pass::::BEGIN@9Test2::Event::Pass::BEGIN@9
1114µs57µsTest2::Event::Pass::::BEGIN@15Test2::Event::Pass::BEGIN@15
1114µs20µsTest2::Event::Pass::::BEGIN@3Test2::Event::Pass::BEGIN@3
111400ns400nsTest2::Event::Pass::::__ANON__Test2::Event::Pass::__ANON__ (xsub)
0000s0sTest2::Event::Pass::::add_infoTest2::Event::Pass::add_info
0000s0sTest2::Event::Pass::::causes_failTest2::Event::Pass::causes_fail
0000s0sTest2::Event::Pass::::diagnosticsTest2::Event::Pass::diagnostics
0000s0sTest2::Event::Pass::::facet_dataTest2::Event::Pass::facet_data
0000s0sTest2::Event::Pass::::globalTest2::Event::Pass::global
0000s0sTest2::Event::Pass::::increments_countTest2::Event::Pass::increments_count
0000s0sTest2::Event::Pass::::no_displayTest2::Event::Pass::no_display
0000s0sTest2::Event::Pass::::sets_planTest2::Event::Pass::sets_plan
0000s0sTest2::Event::Pass::::subtest_idTest2::Event::Pass::subtest_id
0000s0sTest2::Event::Pass::::summaryTest2::Event::Pass::summary
0000s0sTest2::Event::Pass::::terminateTest2::Event::Pass::terminate
Call graph for these subroutines as a Graphviz dot language file.
Line State
ments
Time
on line
Calls Time
in subs
Code
1package Test2::Event::Pass;
2221µs214µs
# spent 12µs (11+2) within Test2::Event::Pass::BEGIN@2 which was called: # once (11µs+2µs) by Test::Builder::BEGIN@18 at line 2
use strict;
# spent 12µs making 1 call to Test2::Event::Pass::BEGIN@2 # spent 2µs making 1 call to strict::import
3227µs237µs
# spent 20µs (4+16) within Test2::Event::Pass::BEGIN@3 which was called: # once (4µs+16µs) by Test::Builder::BEGIN@18 at line 3
use warnings;
# spent 20µs making 1 call to Test2::Event::Pass::BEGIN@3 # spent 16µs making 1 call to warnings::import
4
51300nsour $VERSION = '1.302198';
6
7255µs223µs
# spent 23µs (23+400ns) within Test2::Event::Pass::BEGIN@7 which was called: # once (23µs+400ns) by Test::Builder::BEGIN@18 at line 7
use Test2::EventFacet::Info;
# spent 23µs making 1 call to Test2::Event::Pass::BEGIN@7 # spent 400ns making 1 call to Test2::Event::Pass::__ANON__
8
9
# spent 8µs within Test2::Event::Pass::BEGIN@9 which was called: # once (8µs+0s) by Test::Builder::BEGIN@18 at line 13
BEGIN {
101300ns require Test2::Event;
1115µs our @ISA = qw(Test2::Event);
1213µs *META_KEY = \&Test2::Util::ExternalMeta::META_KEY;
13116µs18µs}
# spent 8µs making 1 call to Test2::Event::Pass::BEGIN@9
14
152159µs2110µs
# spent 57µs (4+53) within Test2::Event::Pass::BEGIN@15 which was called: # once (4µs+53µs) by Test::Builder::BEGIN@18 at line 15
use Test2::Util::HashBase qw{ -name -info };
# spent 57µs making 1 call to Test2::Event::Pass::BEGIN@15 # spent 53µs making 1 call to Test2::Util::HashBase::import
16
17##############
18# Old API
19sub summary { "pass" }
20sub increments_count { 1 }
21sub causes_fail { 0 }
22sub diagnostics { 0 }
23sub no_display { 0 }
24sub subtest_id { undef }
25sub terminate { () }
26sub global { () }
27sub sets_plan { () }
28
29##############
30# New API
31
32sub add_info {
33 my $self = shift;
34
35 for my $in (@_) {
36 $in = {%$in} if ref($in) ne 'ARRAY';
37 $in = Test2::EventFacet::Info->new($in);
38
39 push @{$self->{+INFO}} => $in;
40 }
41}
42
43sub facet_data {
44 my $self = shift;
45
46 my $out = $self->common_facet_data;
47
48 $out->{about}->{details} = 'pass';
49
50 $out->{assert} = {pass => 1, details => $self->{+NAME}};
51
52 $out->{info} = [map {{ %{$_} }} @{$self->{+INFO}}] if $self->{+INFO};
53
54 return $out;
55}
56
5712µs1;
58
59__END__
 
# spent 400ns within Test2::Event::Pass::__ANON__ which was called: # once (400ns+0s) by Test2::Event::Pass::BEGIN@7 at line 7
sub Test2::Event::Pass::__ANON__; # xsub