Linux server.nvwebsoft.co.in 3.10.0-1160.114.2.el7.x86_64 #1 SMP Wed Mar 20 15:54:52 UTC 2024 x86_64
Apache
: 162.240.12.249 | : 3.17.78.182
202 Domain
8.1.31
nbspublicschool
www.github.com/MadExploits
Terminal
AUTO ROOT
Adminer
Backdoor Destroyer
Linux Exploit
Lock Shell
Lock File
Create User
CREATE RDP
PHP Mailer
BACKCONNECT
UNLOCK SHELL
HASH IDENTIFIER
CPANEL RESET
CREATE WP USER
README
+ Create Folder
+ Create File
/
usr /
local /
share /
man /
man3 /
[ HOME SHELL ]
Name
Size
Permission
Action
App::cpanminus.3pm
14.28
KB
-r--r--r--
App::cpanminus::fatscript.3pm
26.28
KB
-r--r--r--
Bundle::DBD::mysql.3pm
4.09
KB
-r--r--r--
CPAN::Meta::Requirements.3pm
13.78
KB
-r--r--r--
CPAN::Meta::YAML.3pm
5.89
KB
-r--r--r--
Canary::Stability.3pm
5.84
KB
-r--r--r--
DBD::mysql.3pm
48.68
KB
-r--r--r--
DBD::mysql::INSTALL.3pm
30.13
KB
-r--r--r--
Data::Dump.3pm
10.51
KB
-r--r--r--
Data::Dump::Filtered.3pm
10.39
KB
-r--r--r--
Data::Dump::Trace.3pm
9
KB
-r--r--r--
Data::Validate::IP.3pm
15.68
KB
-r--r--r--
Devel::CheckLib.3pm
11.45
KB
-r--r--r--
Digest::MD5.3pm
16.16
KB
-r--r--r--
Error.3pm
21.39
KB
-r--r--r--
Error::Simple.3pm
8.15
KB
-r--r--r--
Expect.3pm
60.58
KB
-r--r--r--
Exporter.3pm
22.74
KB
-r--r--r--
Exporter::Heavy.3pm
4.1
KB
-r--r--r--
File::Copy::Recursive.3pm
18.63
KB
-r--r--r--
File::LckPwdF.3pm
11.21
KB
-r--r--r--
File::Path.3pm
32.74
KB
-r--r--r--
File::ReadBackwards.3pm
10.38
KB
-r--r--r--
File::Temp.3pm
39.49
KB
-r--r--r--
HTML::TagParser.3pm
14.01
KB
-r--r--r--
HTTP::Date.3pm
9.36
KB
-r--r--r--
HTTP::Tiny.3pm
29.24
KB
-r--r--r--
IO::AtomicFile.3pm
7.02
KB
-r--r--r--
IO::InnerFile.3pm
7.66
KB
-r--r--r--
IO::Lines.3pm
5.46
KB
-r--r--r--
IO::Pty.3pm
10.14
KB
-r--r--r--
IO::Scalar.3pm
12.19
KB
-r--r--r--
IO::ScalarArray.3pm
12.04
KB
-r--r--r--
IO::Stringy.3pm
5.72
KB
-r--r--r--
IO::Tty.3pm
9.91
KB
-r--r--r--
IO::Tty::Constant.3pm
11.25
KB
-r--r--r--
IO::Wrap.3pm
12.18
KB
-r--r--r--
IO::WrapTie.3pm
16.4
KB
-r--r--r--
JSON.3pm
64.46
KB
-r--r--r--
JSON::Syck.3pm
9.67
KB
-r--r--r--
JSON::XS.3pm
88.67
KB
-r--r--r--
JSON::XS::Boolean.3pm
4.55
KB
-r--r--r--
JSON::backportPP.3pm
65.09
KB
-r--r--r--
JSON::backportPP::Boolean.3pm
4.52
KB
-r--r--r--
JSON::backportPP::Compat5005.3...
4.39
KB
-r--r--r--
JSON::backportPP::Compat5006.3...
4.39
KB
-r--r--r--
Mail::RFC822::Address.3pm
7.11
KB
-r--r--r--
Mock::Config.3pm
7.73
KB
-r--r--r--
Module::Load.3pm
11.18
KB
-r--r--r--
Module::Load::Conditional.3pm
14.24
KB
-r--r--r--
NetAddr::IP.3pm
38.15
KB
-r--r--r--
NetAddr::IP::InetBase.3pm
14.65
KB
-r--r--r--
NetAddr::IP::Lite.3pm
26.89
KB
-r--r--r--
NetAddr::IP::Util.3pm
23.49
KB
-r--r--r--
NetAddr::IP::UtilPP.3pm
11.04
KB
-r--r--r--
POD2::DE::local::lib.3pm
24.23
KB
-r--r--r--
POD2::PT_BR::local::lib.3pm
24.62
KB
-r--r--r--
Path::Tiny.3pm
52.88
KB
-r--r--r--
Storable.3pm
45.41
KB
-r--r--r--
Template::Toolkit::Simple.3pm
13.37
KB
-r--r--r--
Test2.3pm
11.13
KB
-r--r--r--
Test2::API.3pm
37.22
KB
-r--r--r--
Test2::API::Breakage.3pm
6.63
KB
-r--r--r--
Test2::API::Context.3pm
25.52
KB
-r--r--r--
Test2::API::Instance.3pm
14.72
KB
-r--r--r--
Test2::API::InterceptResult.3p...
22
KB
-r--r--r--
Test2::API::InterceptResult::E...
26.72
KB
-r--r--r--
Test2::API::InterceptResult::H...
4.64
KB
-r--r--r--
Test2::API::InterceptResult::S...
4.77
KB
-r--r--r--
Test2::API::Stack.3pm
8.18
KB
-r--r--r--
Test2::Event.3pm
22.81
KB
-r--r--r--
Test2::Event::Bail.3pm
5.15
KB
-r--r--r--
Test2::Event::Diag.3pm
5.02
KB
-r--r--r--
Test2::Event::Encoding.3pm
5.36
KB
-r--r--r--
Test2::Event::Exception.3pm
5.3
KB
-r--r--r--
Test2::Event::Fail.3pm
4.93
KB
-r--r--r--
Test2::Event::Generic.3pm
9.66
KB
-r--r--r--
Test2::Event::Note.3pm
5.01
KB
-r--r--r--
Test2::Event::Ok.3pm
5.69
KB
-r--r--r--
Test2::Event::Pass.3pm
4.93
KB
-r--r--r--
Test2::Event::Plan.3pm
5.58
KB
-r--r--r--
Test2::Event::Skip.3pm
5.34
KB
-r--r--r--
Test2::Event::Subtest.3pm
5.25
KB
-r--r--r--
Test2::Event::TAP::Version.3pm
5.18
KB
-r--r--r--
Test2::Event::V2.3pm
8.26
KB
-r--r--r--
Test2::Event::Waiting.3pm
4.8
KB
-r--r--r--
Test2::EventFacet.3pm
5.57
KB
-r--r--r--
Test2::EventFacet::About.3pm
6.37
KB
-r--r--r--
Test2::EventFacet::Amnesty.3pm
6.16
KB
-r--r--r--
Test2::EventFacet::Assert.3pm
6.41
KB
-r--r--r--
Test2::EventFacet::Control.3pm
7.4
KB
-r--r--r--
Test2::EventFacet::Error.3pm
6.26
KB
-r--r--r--
Test2::EventFacet::Hub.3pm
7.12
KB
-r--r--r--
Test2::EventFacet::Info.3pm
8.17
KB
-r--r--r--
Test2::EventFacet::Info::Table...
7.16
KB
-r--r--r--
Test2::EventFacet::Meta.3pm
5.22
KB
-r--r--r--
Test2::EventFacet::Parent.3pm
6.31
KB
-r--r--r--
Test2::EventFacet::Plan.3pm
6.67
KB
-r--r--r--
Test2::EventFacet::Render.3pm
6.84
KB
-r--r--r--
Test2::EventFacet::Trace.3pm
12.58
KB
-r--r--r--
Test2::Formatter.3pm
7.9
KB
-r--r--r--
Test2::Formatter::TAP.3pm
6.38
KB
-r--r--r--
Test2::Hub.3pm
18.36
KB
-r--r--r--
Test2::Hub::Interceptor.3pm
4.63
KB
-r--r--r--
Test2::Hub::Interceptor::Termi...
4.67
KB
-r--r--r--
Test2::Hub::Subtest.3pm
5.48
KB
-r--r--r--
Test2::IPC.3pm
5.18
KB
-r--r--r--
Test2::IPC::Driver.3pm
10.51
KB
-r--r--r--
Test2::IPC::Driver::Files.3pm
5.49
KB
-r--r--r--
Test2::Tools::Tiny.3pm
8.45
KB
-r--r--r--
Test2::Transition.3pm
19.71
KB
-r--r--r--
Test2::Util.3pm
9.42
KB
-r--r--r--
Test2::Util::ExternalMeta.3pm
7.22
KB
-r--r--r--
Test2::Util::Facets2Legacy.3pm
9.88
KB
-r--r--r--
Test2::Util::HashBase.3pm
13.91
KB
-r--r--r--
Test2::Util::Trace.3pm
4.74
KB
-r--r--r--
Test::Builder.3pm
28.79
KB
-r--r--r--
Test::Builder::Formatter.3pm
4.85
KB
-r--r--r--
Test::Builder::IO::Scalar.3pm
11.27
KB
-r--r--r--
Test::Builder::Module.3pm
7.35
KB
-r--r--r--
Test::Builder::Tester.3pm
13.04
KB
-r--r--r--
Test::Builder::Tester::Color.3...
4.82
KB
-r--r--r--
Test::Builder::TodoDiag.3pm
4.82
KB
-r--r--r--
Test::Deep.3pm
47.56
KB
-r--r--r--
Test::Deep::NoTest.3pm
4.33
KB
-r--r--r--
Test::Fatal.3pm
10.69
KB
-r--r--r--
Test::File.3pm
23.7
KB
-r--r--r--
Test::More.3pm
43.96
KB
-r--r--r--
Test::Needs.3pm
7.27
KB
-r--r--r--
Test::Requires.3pm
5.93
KB
-r--r--r--
Test::Simple.3pm
10.67
KB
-r--r--r--
Test::Tester.3pm
17.76
KB
-r--r--r--
Test::Tester::Capture.3pm
4.59
KB
-r--r--r--
Test::Tester::CaptureRunner.3p...
4.37
KB
-r--r--r--
Test::Tutorial.3pm
25.46
KB
-r--r--r--
Test::Warnings.3pm
15.7
KB
-r--r--r--
Test::use::ok.3pm
5.52
KB
-r--r--r--
Text::Aligner.3pm
9.77
KB
-r--r--r--
Text::Table.3pm
27.18
KB
-r--r--r--
Time::Local.3pm
15.63
KB
-r--r--r--
Try::Tiny.3pm
22.09
KB
-r--r--r--
URI.3pm
40.31
KB
-r--r--r--
URI::Escape.3pm
9.58
KB
-r--r--r--
URI::Heuristic.3pm
6.84
KB
-r--r--r--
URI::QueryParam.3pm
8.26
KB
-r--r--r--
URI::Split.3pm
5.73
KB
-r--r--r--
URI::URL.3pm
6.19
KB
-r--r--r--
URI::WithBase.3pm
5.91
KB
-r--r--r--
URI::_punycode.3pm
6.32
KB
-r--r--r--
URI::data.3pm
5.98
KB
-r--r--r--
URI::file.3pm
12.16
KB
-r--r--r--
URI::ldap.3pm
7.36
KB
-r--r--r--
YAML::LibYAML.3pm
4.51
KB
-r--r--r--
YAML::Syck.3pm
12.34
KB
-r--r--r--
YAML::XS.3pm
9.57
KB
-r--r--r--
YAML::XS::LibYAML.3pm
3.99
KB
-r--r--r--
lib::core::only.3pm
7.28
KB
-r--r--r--
local::lib.3pm
32.78
KB
-r--r--r--
ok.3pm
4.55
KB
-r--r--r--
version.3pm
15.37
KB
-r--r--r--
version::Internals.3pm
31.34
KB
-r--r--r--
Delete
Unzip
Zip
${this.title}
Close
Code Editor : Test2::API::InterceptResult::Event.3pm
.\" Automatically generated by Pod::Man 2.27 (Pod::Simple 3.28) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is turned on, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{ . if \nF \{ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" .\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2). .\" Fear. Run. Save yourself. No user-serviceable parts. . \" fudge factors for nroff and troff .if n \{\ . ds #H 0 . ds #V .8m . ds #F .3m . ds #[ \f1 . ds #] \fP .\} .if t \{\ . ds #H ((1u-(\\\\n(.fu%2u))*.13m) . ds #V .6m . ds #F 0 . ds #[ \& . ds #] \& .\} . \" simple accents for nroff and troff .if n \{\ . ds ' \& . ds ` \& . ds ^ \& . ds , \& . ds ~ ~ . ds / .\} .if t \{\ . ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u" . ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u' . ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u' . ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u' . ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u' . ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u' .\} . \" troff and (daisy-wheel) nroff accents .ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V' .ds 8 \h'\*(#H'\(*b\h'-\*(#H' .ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#] .ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H' .ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u' .ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#] .ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#] .ds ae a\h'-(\w'a'u*4/10)'e .ds Ae A\h'-(\w'A'u*4/10)'E . \" corrections for vroff .if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u' .if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u' . \" for low resolution devices (crt and lpr) .if \n(.H>23 .if \n(.V>19 \ \{\ . ds : e . ds 8 ss . ds o a . ds d- d\h'-1'\(ga . ds D- D\h'-1'\(hy . ds th \o'bp' . ds Th \o'LP' . ds ae ae . ds Ae AE .\} .rm #[ #] #H #V #F C .\" ======================================================================== .\" .IX Title "Test2::API::InterceptResult::Event 3" .TH Test2::API::InterceptResult::Event 3 "2022-03-04" "perl v5.16.3" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" Test2::API::InterceptResult::Event \- Representation of an event for use in testing other test tools. .SH "DESCRIPTION" .IX Header "DESCRIPTION" \&\f(CW\*(C`intercept { ... }\*(C'\fR from Test2::API returns an instance of Test2::API::InterceptResult which is a blessed arrayref of Test2::API::InterceptResult::Event objects. .PP This \s-1POD\s0 documents the methods of these events, which are mainly provided for you to use when testing your test tools. .SH "SYNOPSIS" .IX Header "SYNOPSIS" .Vb 2 \& use Test2::V0; \& use Test2::API qw/intercept/; \& \& my $events = intercept { \& ok(1, "A passing assertion"); \& plan(1); \& }; \& \& # This will convert all events into instances of \& # Test2::API::InterceptResult::Event. Until we do this they are the \& # original Test::Event::* instances \& $events\->upgrade(in_place => 1); \& \& # Now we can get individual events in this form \& my $assert = $events\->[0]; \& my $plan = $events\->[1]; \& \& # Or we can operate on all events at once: \& my $flattened = $events\->flatten; \& is( \& $flattened, \& [ \& { \& causes_failure => 0, \& \& name => \*(AqA passing assertion\*(Aq, \& pass => 1, \& \& trace_file => \*(Aqxxx.t\*(Aq, \& trace_line => 5, \& }, \& { \& causes_failure => 0, \& \& plan => 1, \& \& trace_file => \*(Aqxxx.t\*(Aq, \& trace_line => 6, \& }, \& ], \& "Flattened both events and returned an arrayref of the results \& ); .Ve .SH "METHODS" .IX Header "METHODS" .SS "!!! \s-1IMPORTANT NOTES ON DESIGN \s0!!!" .IX Subsection "!!! IMPORTANT NOTES ON DESIGN !!!" Please pay attention to what these return, many return a scalar when applicable or an empty list when not (as opposed to undef). Many also always return a list of 0 or more items. Some always return a scalar. Note that none of the methods care about context, their behavior is consistent regardless of scalar, list, or void context. .PP This was done because this class was specifically designed to be used in a list and generate more lists in bulk operations. Sometimes in a map you want nothing to show up for the event, and you do not want an undef in its place. In general single event instances are not going to be used alone, though that is allowed. .PP As a general rule any method prefixed with \f(CW\*(C`the_\*(C'\fR implies the event should have exactly 1 of the specified item, and and exception will be thrown if there are 0, or more than 1 of the item. .SS "\s-1ATTRIBUTES\s0" .IX Subsection "ATTRIBUTES" .ie n .IP "$hashref = $event\->facet_data" 4 .el .IP "\f(CW$hashref\fR = \f(CW$event\fR\->facet_data" 4 .IX Item "$hashref = $event->facet_data" This will return the facet data hashref, which is all Test2 cares about for any given event. .ie n .IP "$class = $event\->result_class" 4 .el .IP "\f(CW$class\fR = \f(CW$event\fR\->result_class" 4 .IX Item "$class = $event->result_class" This is normally Test2::API::InterceptResult. This is set at construction so that subtest results can be turned into instances of it on demand. .SS "\s-1DUPLICATION\s0" .IX Subsection "DUPLICATION" .ie n .IP "$copy = $event\->clone" 4 .el .IP "\f(CW$copy\fR = \f(CW$event\fR\->clone" 4 .IX Item "$copy = $event->clone" Create a deep copy of the event. Modifying either event will not effect the other. .SS "\s-1CONDENSED\s0 MULTI-FACET \s-1DATA\s0" .IX Subsection "CONDENSED MULTI-FACET DATA" .ie n .IP "$bool = $event\->causes_failure" 4 .el .IP "\f(CW$bool\fR = \f(CW$event\fR\->causes_failure" 4 .IX Item "$bool = $event->causes_failure" .PD 0 .ie n .IP "$bool = $event\->causes_fail" 4 .el .IP "\f(CW$bool\fR = \f(CW$event\fR\->causes_fail" 4 .IX Item "$bool = $event->causes_fail" .PD These are both aliases of the same functionality. .Sp This will always return either a true value, or a false value. This never returns a list. .Sp This method may be relatively slow (still super fast) because it determines pass or fail by creating an instance of Test2::Hub and asking it to process the event, and then asks the hub for its pass/fail state. This is slower than bulding in logic to do the check, but it is more reliable as it will always tell you what the hub thinks, so the logic will never be out of date relative to the Test2 logic that actually cares. .ie n .IP "\s-1STRING_OR_EMPTY_LIST\s0 = $event\->brief" 4 .el .IP "\s-1STRING_OR_EMPTY_LIST\s0 = \f(CW$event\fR\->brief" 4 .IX Item "STRING_OR_EMPTY_LIST = $event->brief" Not all events have a brief, some events are not rendered by the formatter, others have no \*(L"brief\*(R" data worth seeing. When this is the case an empty list is returned. This is done intentionally so it can be used in a map operation without having \f(CW\*(C`undef\*(C'\fR being included in the result. .Sp When a brief can be generated it is always a single 1\-line string, and is returned as-is, not in a list. .Sp Possible briefs: .Sp .Vb 3 \& # From control facets \& "BAILED OUT" \& "BAILED OUT: $why" \& \& # From error facets \& "ERROR" \& "ERROR: $message" \& "ERROR: $partial_message [...]" \& "ERRORS: $first_error_message [...]" \& \& # From assert facets \& "PASS" \& "FAIL" \& "PASS with amnesty" \& "FAIL with amnesty" \& \& # From plan facets \& "PLAN $count" \& "NO PLAN" \& "SKIP ALL" \& "SKIP ALL: $why" .Ve .Sp Note that only the first applicable brief is returned. This is essnetially a poor-mans \s-1TAP\s0 that only includes facets that could (but not necessarily do) cause a failure. .ie n .IP "$hashref = $event\->flatten" 4 .el .IP "\f(CW$hashref\fR = \f(CW$event\fR\->flatten" 4 .IX Item "$hashref = $event->flatten" .PD 0 .ie n .IP "$hashref = $event\->flatten(include_subevents => 1)" 4 .el .IP "\f(CW$hashref\fR = \f(CW$event\fR\->flatten(include_subevents => 1)" 4 .IX Item "$hashref = $event->flatten(include_subevents => 1)" .PD This \s-1ALWAYS\s0 returns a hashref. This puts all the most useful data for the most interesting facets into a single hashref for easy validation. .Sp If there are no meaningful facets this will return an empty hashref. .Sp If given the 'include_subevents' parameter it will also include subtest data: .Sp Here is a list of \s-1EVERY\s0 possible field. If a field is not applicable it will not be present. .RS 4 .IP "always present" 4 .IX Item "always present" .Vb 1 \& causes_failure => 1, # Always present .Ve .IP "Present if the event has a trace facet" 4 .IX Item "Present if the event has a trace facet" .Vb 3 \& trace_line => 42, \& trace_file => \*(AqFoo/Bar.pm\*(Aq, \& trace_details => \*(AqExtra trace details\*(Aq, # usually not present .Ve .IP "If an assertion is present" 4 .IX Item "If an assertion is present" .Vb 2 \& pass => 0, \& name => "1 + 1 = 2, so math works", .Ve .IP "If a plan is present:" 4 .IX Item "If a plan is present:" .Vb 1 \& plan => $count_or_SKIP_ALL_or_NO_PLAN, .Ve .IP "If amnesty facets are present" 4 .IX Item "If amnesty facets are present" You get an array for each type that is present. .Sp .Vb 4 \& todo => [ # Yes you could be under multiple todos, this will list them all. \& "I will fix this later", \& "I promise to fix these", \& ], \& \& skip => ["This will format the main drive, do not run"], \& \& ... => ["Other amnesty"] .Ve .IP "If Info (note/diag) facets are present" 4 .IX Item "If Info (note/diag) facets are present" You get an arrayref for any that are present, the key is not defined if they are not present. .Sp .Vb 4 \& diag => [ \& "Test failed at Foo/Bar.pm line 42", \& "You forgot to tie your boots", \& ], \& \& note => ["Your boots are red"], \& \& ... => ["Other info"], .Ve .IP "If error facets are present" 4 .IX Item "If error facets are present" Always an arrayref .Sp .Vb 4 \& error => [ \& "non fatal error (does not cause test failure, just an FYI", \& "FATAL: This is a fatal error (causes failure)", \& ], \& \& # Errors can have alternative tags, but in practice are always \*(Aqerror\*(Aq, \& # listing this for completeness. \& ... => [ ... ] .Ve .IP "Present if the event is a subtest" 4 .IX Item "Present if the event is a subtest" .Vb 5 \& subtest => { \& count => 2, # Number of assertions made \& failed => 1, # Number of test failures seen \& is_passing => 0, # Boolean, true if the test would be passing \& # after the events are processed. \& \& plan => 2, # Plan, either a number, undef, \*(AqSKIP\*(Aq, or \*(AqNO PLAN\*(Aq \& follows_plan => 1, # True if there is a plan and it was followed. \& # False if the plan and assertions did not \& # match, undef if no plan was present in the \& # event list. \& \& bailed_out => "foo", # if there was a bail\-out in the \& # events in this will be a string explaining \& # why there was a bailout, if no reason was \& # given this will simply be set to true (1). \& \& skip_reason => "foo", # If there was a skip_all this will give the \& # reason. \& }, .Ve .Sp if \f(CW\*(C`(include_subtest => 1)\*(C'\fR was provided as a parameter then the following will be included. This is the result of turning all subtest child events into an Test2::API::InterceptResult instance and calling the \f(CW\*(C`flatten\*(C'\fR method on it. .Sp .Vb 1 \& subevents => Test2::API::InterceptResult\->new(@child_events)\->flatten(...), .Ve .IP "If a bail-out is being requested" 4 .IX Item "If a bail-out is being requested" If no reason was given this will be set to 1. .Sp .Vb 1 \& bailed_out => "reason", .Ve .RE .RS 4 .RE .ie n .IP "$hashref = $event\->\fIsummary()\fR" 4 .el .IP "\f(CW$hashref\fR = \f(CW$event\fR\->\fIsummary()\fR" 4 .IX Item "$hashref = $event->summary()" This returns a limited summary. See \f(CW\*(C`flatten()\*(C'\fR, which is usually a better option. .Sp .Vb 2 \& { \& brief => $event\->brief || \*(Aq\*(Aq, \& \& causes_failure => $event\->causes_failure, \& \& trace_line => $event\->trace_line, \& trace_file => $event\->trace_file, \& trace_tool => $event\->trace_subname, \& trace_details => $event\->trace_details, \& \& facets => [ sort keys(%{$event\->{+FACET_DATA}}) ], \& } .Ve .SS "\s-1DIRECT ARBITRARY FACET ACCESS\s0" .IX Subsection "DIRECT ARBITRARY FACET ACCESS" .ie n .IP "@list_of_facets = $event\->facet($name)" 4 .el .IP "\f(CW@list_of_facets\fR = \f(CW$event\fR\->facet($name)" 4 .IX Item "@list_of_facets = $event->facet($name)" This always returns a list of 0 or more items. This fetches the facet instances from the event. For facets like 'assert' this will always return 0 or 1 item. For events like 'info' (diags, notes) this will return 0 or more instances, once for each instance of the facet. .Sp These will be blessed into the proper Test2::EventFacet subclass. If no subclass can be found it will be blessed as an Test2::API::InterceptResult::Facet generic facet class. .ie n .IP "$undef_or_facet = $event\->the_facet($name)" 4 .el .IP "\f(CW$undef_or_facet\fR = \f(CW$event\fR\->the_facet($name)" 4 .IX Item "$undef_or_facet = $event->the_facet($name)" If you know you will have exactly 1 instance of a facet you can call this. .Sp If you are correct and there is exactly one instance of the facet it will always return the hashref. .Sp If there are 0 instances of the facet this will reutrn undef, not an empty list. .Sp If there are more than 1 instance this will throw an exception because your assumption was incorrect. .SS "\s-1TRACE FACET\s0" .IX Subsection "TRACE FACET" .ie n .IP "@list_of_facets = $event\->trace" 4 .el .IP "\f(CW@list_of_facets\fR = \f(CW$event\fR\->trace" 4 .IX Item "@list_of_facets = $event->trace" \&\s-1TODO\s0 .ie n .IP "$undef_or_hashref = $event\->the_trace" 4 .el .IP "\f(CW$undef_or_hashref\fR = \f(CW$event\fR\->the_trace" 4 .IX Item "$undef_or_hashref = $event->the_trace" This returns the trace hashref, or undef if it is not present. .ie n .IP "$undef_or_arrayref = $event\->frame" 4 .el .IP "\f(CW$undef_or_arrayref\fR = \f(CW$event\fR\->frame" 4 .IX Item "$undef_or_arrayref = $event->frame" If a trace is present, and has a caller frame, this will be an arrayref: .Sp .Vb 1 \& [$package, $file, $line, $subname] .Ve .Sp If the trace is not present, or has no caller frame this will return undef. .ie n .IP "$undef_or_string = $event\->trace_details" 4 .el .IP "\f(CW$undef_or_string\fR = \f(CW$event\fR\->trace_details" 4 .IX Item "$undef_or_string = $event->trace_details" This is usually undef, but occasionally has a string that overrides the file/line number debugging a trace usually provides on test failure. .ie n .IP "$undef_or_string = $event\->trace_package" 4 .el .IP "\f(CW$undef_or_string\fR = \f(CW$event\fR\->trace_package" 4 .IX Item "$undef_or_string = $event->trace_package" Same as \f(CW\*(C`(caller())[0]\*(C'\fR, the first element of the trace frame. .Sp Will be undef if not present. .ie n .IP "$undef_or_string = $event\->trace_file" 4 .el .IP "\f(CW$undef_or_string\fR = \f(CW$event\fR\->trace_file" 4 .IX Item "$undef_or_string = $event->trace_file" Same as \f(CW\*(C`(caller())[1]\*(C'\fR, the second element of the trace frame. .Sp Will be undef if not present. .ie n .IP "$undef_or_integer = $event\->trace_line" 4 .el .IP "\f(CW$undef_or_integer\fR = \f(CW$event\fR\->trace_line" 4 .IX Item "$undef_or_integer = $event->trace_line" Same as \f(CW\*(C`(caller())[2]\*(C'\fR, the third element of the trace frame. .Sp Will be undef if not present. .ie n .IP "$undef_or_string = $event\->trace_subname" 4 .el .IP "\f(CW$undef_or_string\fR = \f(CW$event\fR\->trace_subname" 4 .IX Item "$undef_or_string = $event->trace_subname" .PD 0 .ie n .IP "$undef_or_string = $event\->trace_tool" 4 .el .IP "\f(CW$undef_or_string\fR = \f(CW$event\fR\->trace_tool" 4 .IX Item "$undef_or_string = $event->trace_tool" .PD Aliases for the same thing .Sp Same as \f(CW\*(C`(caller($level))[4]\*(C'\fR, the fourth element of the trace frame. .Sp Will be undef if not present. .ie n .IP "$undef_or_string = $event\->trace_signature" 4 .el .IP "\f(CW$undef_or_string\fR = \f(CW$event\fR\->trace_signature" 4 .IX Item "$undef_or_string = $event->trace_signature" A string that is a unique signature for the trace. If a single context generates multiple events they will all have the same signature. This can be used to tie assertions and diagnostics sent as seperate events together after the fact. .SS "\s-1ASSERT FACET\s0" .IX Subsection "ASSERT FACET" .ie n .IP "$bool = $event\->has_assert" 4 .el .IP "\f(CW$bool\fR = \f(CW$event\fR\->has_assert" 4 .IX Item "$bool = $event->has_assert" Returns true if the event has an assert facet, false if it does not. .ie n .IP "$undef_or_hashref = $event\->the_assert" 4 .el .IP "\f(CW$undef_or_hashref\fR = \f(CW$event\fR\->the_assert" 4 .IX Item "$undef_or_hashref = $event->the_assert" Returns the assert facet if present, undef if it is not. .ie n .IP "@list_of_facets = $event\->assert" 4 .el .IP "\f(CW@list_of_facets\fR = \f(CW$event\fR\->assert" 4 .IX Item "@list_of_facets = $event->assert" \&\s-1TODO\s0 .ie n .IP "\s-1EMPTY_LIST_OR_STRING\s0 = $event\->assert_brief" 4 .el .IP "\s-1EMPTY_LIST_OR_STRING\s0 = \f(CW$event\fR\->assert_brief" 4 .IX Item "EMPTY_LIST_OR_STRING = $event->assert_brief" Returns a string giving a brief of the assertion if an assertion is present. Returns an empty list if no assertion is present. .SS "\s-1SUBTESTS \s0(\s-1PARENT FACET\s0)" .IX Subsection "SUBTESTS (PARENT FACET)" .ie n .IP "$bool = $event\->has_subtest" 4 .el .IP "\f(CW$bool\fR = \f(CW$event\fR\->has_subtest" 4 .IX Item "$bool = $event->has_subtest" True if a subetest is present in this event. .ie n .IP "$undef_or_hashref = $event\->the_subtest" 4 .el .IP "\f(CW$undef_or_hashref\fR = \f(CW$event\fR\->the_subtest" 4 .IX Item "$undef_or_hashref = $event->the_subtest" Get the one subtest if present, otherwise undef. .ie n .IP "@list_of_facets = $event\->subtest" 4 .el .IP "\f(CW@list_of_facets\fR = \f(CW$event\fR\->subtest" 4 .IX Item "@list_of_facets = $event->subtest" \&\s-1TODO\s0 .ie n .IP "\s-1EMPTY_LIST_OR_OBJECT\s0 = $event\->subtest_result" 4 .el .IP "\s-1EMPTY_LIST_OR_OBJECT\s0 = \f(CW$event\fR\->subtest_result" 4 .IX Item "EMPTY_LIST_OR_OBJECT = $event->subtest_result" Returns an empty list if there is no subtest. .Sp Get an instance of Test2::API::InterceptResult representing the subtest. .SS "\s-1CONTROL FACET \s0(\s-1BAILOUT, ENCODING\s0)" .IX Subsection "CONTROL FACET (BAILOUT, ENCODING)" .ie n .IP "$bool = $event\->has_bailout" 4 .el .IP "\f(CW$bool\fR = \f(CW$event\fR\->has_bailout" 4 .IX Item "$bool = $event->has_bailout" True if there was a bailout .ie n .IP "$undef_hashref = $event\->the_bailout" 4 .el .IP "\f(CW$undef_hashref\fR = \f(CW$event\fR\->the_bailout" 4 .IX Item "$undef_hashref = $event->the_bailout" Return the control facet if it requested a bailout. .ie n .IP "\s-1EMPTY_LIST_OR_HASHREF\s0 = $event\->bailout" 4 .el .IP "\s-1EMPTY_LIST_OR_HASHREF\s0 = \f(CW$event\fR\->bailout" 4 .IX Item "EMPTY_LIST_OR_HASHREF = $event->bailout" Get a list of 0 or 1 hashrefs. The hashref will be the control facet if a bail-out was requested. .ie n .IP "\s-1EMPTY_LIST_OR_STRING\s0 = $event\->bailout_brief" 4 .el .IP "\s-1EMPTY_LIST_OR_STRING\s0 = \f(CW$event\fR\->bailout_brief" 4 .IX Item "EMPTY_LIST_OR_STRING = $event->bailout_brief" Get the brief of the balout if present. .ie n .IP "\s-1EMPTY_LIST_OR_STRING\s0 = $event\->bailout_reason" 4 .el .IP "\s-1EMPTY_LIST_OR_STRING\s0 = \f(CW$event\fR\->bailout_reason" 4 .IX Item "EMPTY_LIST_OR_STRING = $event->bailout_reason" Get the reason for the bailout, an empty string if no reason was provided, or an empty list if there was no bailout. .SS "\s-1PLAN FACET\s0" .IX Subsection "PLAN FACET" \&\s-1TODO\s0 .ie n .IP "$bool = $event\->has_plan" 4 .el .IP "\f(CW$bool\fR = \f(CW$event\fR\->has_plan" 4 .IX Item "$bool = $event->has_plan" .PD 0 .ie n .IP "$undef_or_hashref = $event\->the_plan" 4 .el .IP "\f(CW$undef_or_hashref\fR = \f(CW$event\fR\->the_plan" 4 .IX Item "$undef_or_hashref = $event->the_plan" .ie n .IP "@list_if_hashrefs = $event\->plan" 4 .el .IP "\f(CW@list_if_hashrefs\fR = \f(CW$event\fR\->plan" 4 .IX Item "@list_if_hashrefs = $event->plan" .ie n .IP "\s-1EMPTY_LIST_OR_STRING\s0 $event\->plan_brief" 4 .el .IP "\s-1EMPTY_LIST_OR_STRING\s0 \f(CW$event\fR\->plan_brief" 4 .IX Item "EMPTY_LIST_OR_STRING $event->plan_brief" .PD .SS "\s-1AMNESTY FACET \s0(\s-1TODO AND SKIP\s0)" .IX Subsection "AMNESTY FACET (TODO AND SKIP)" \&\s-1TODO\s0 .ie n .IP "$event\->has_amnesty" 4 .el .IP "\f(CW$event\fR\->has_amnesty" 4 .IX Item "$event->has_amnesty" .PD 0 .ie n .IP "$event\->the_amnesty" 4 .el .IP "\f(CW$event\fR\->the_amnesty" 4 .IX Item "$event->the_amnesty" .ie n .IP "$event\->amnesty" 4 .el .IP "\f(CW$event\fR\->amnesty" 4 .IX Item "$event->amnesty" .ie n .IP "$event\->amnesty_reasons" 4 .el .IP "\f(CW$event\fR\->amnesty_reasons" 4 .IX Item "$event->amnesty_reasons" .ie n .IP "$event\->has_todos" 4 .el .IP "\f(CW$event\fR\->has_todos" 4 .IX Item "$event->has_todos" .ie n .IP "$event\->todos" 4 .el .IP "\f(CW$event\fR\->todos" 4 .IX Item "$event->todos" .ie n .IP "$event\->todo_reasons" 4 .el .IP "\f(CW$event\fR\->todo_reasons" 4 .IX Item "$event->todo_reasons" .ie n .IP "$event\->has_skips" 4 .el .IP "\f(CW$event\fR\->has_skips" 4 .IX Item "$event->has_skips" .ie n .IP "$event\->skips" 4 .el .IP "\f(CW$event\fR\->skips" 4 .IX Item "$event->skips" .ie n .IP "$event\->skip_reasons" 4 .el .IP "\f(CW$event\fR\->skip_reasons" 4 .IX Item "$event->skip_reasons" .ie n .IP "$event\->has_other_amnesty" 4 .el .IP "\f(CW$event\fR\->has_other_amnesty" 4 .IX Item "$event->has_other_amnesty" .ie n .IP "$event\->other_amnesty" 4 .el .IP "\f(CW$event\fR\->other_amnesty" 4 .IX Item "$event->other_amnesty" .ie n .IP "$event\->other_amnesty_reasons" 4 .el .IP "\f(CW$event\fR\->other_amnesty_reasons" 4 .IX Item "$event->other_amnesty_reasons" .PD .SS "\s-1ERROR FACET \s0(\s-1CAPTURED EXCEPTIONS\s0)" .IX Subsection "ERROR FACET (CAPTURED EXCEPTIONS)" \&\s-1TODO\s0 .ie n .IP "$event\->has_errors" 4 .el .IP "\f(CW$event\fR\->has_errors" 4 .IX Item "$event->has_errors" .PD 0 .ie n .IP "$event\->the_errors" 4 .el .IP "\f(CW$event\fR\->the_errors" 4 .IX Item "$event->the_errors" .ie n .IP "$event\->errors" 4 .el .IP "\f(CW$event\fR\->errors" 4 .IX Item "$event->errors" .ie n .IP "$event\->error_messages" 4 .el .IP "\f(CW$event\fR\->error_messages" 4 .IX Item "$event->error_messages" .ie n .IP "$event\->error_brief" 4 .el .IP "\f(CW$event\fR\->error_brief" 4 .IX Item "$event->error_brief" .PD .SS "\s-1INFO FACET \s0(\s-1DIAG, NOTE\s0)" .IX Subsection "INFO FACET (DIAG, NOTE)" \&\s-1TODO\s0 .ie n .IP "$event\->has_info" 4 .el .IP "\f(CW$event\fR\->has_info" 4 .IX Item "$event->has_info" .PD 0 .ie n .IP "$event\->the_info" 4 .el .IP "\f(CW$event\fR\->the_info" 4 .IX Item "$event->the_info" .ie n .IP "$event\->info" 4 .el .IP "\f(CW$event\fR\->info" 4 .IX Item "$event->info" .ie n .IP "$event\->info_messages" 4 .el .IP "\f(CW$event\fR\->info_messages" 4 .IX Item "$event->info_messages" .ie n .IP "$event\->has_diags" 4 .el .IP "\f(CW$event\fR\->has_diags" 4 .IX Item "$event->has_diags" .ie n .IP "$event\->diags" 4 .el .IP "\f(CW$event\fR\->diags" 4 .IX Item "$event->diags" .ie n .IP "$event\->diag_messages" 4 .el .IP "\f(CW$event\fR\->diag_messages" 4 .IX Item "$event->diag_messages" .ie n .IP "$event\->has_notes" 4 .el .IP "\f(CW$event\fR\->has_notes" 4 .IX Item "$event->has_notes" .ie n .IP "$event\->notes" 4 .el .IP "\f(CW$event\fR\->notes" 4 .IX Item "$event->notes" .ie n .IP "$event\->note_messages" 4 .el .IP "\f(CW$event\fR\->note_messages" 4 .IX Item "$event->note_messages" .ie n .IP "$event\->has_other_info" 4 .el .IP "\f(CW$event\fR\->has_other_info" 4 .IX Item "$event->has_other_info" .ie n .IP "$event\->other_info" 4 .el .IP "\f(CW$event\fR\->other_info" 4 .IX Item "$event->other_info" .ie n .IP "$event\->other_info_messages" 4 .el .IP "\f(CW$event\fR\->other_info_messages" 4 .IX Item "$event->other_info_messages" .PD .SH "SOURCE" .IX Header "SOURCE" The source code repository for Test2 can be found at \&\fIhttp://github.com/Test\-More/test\-more/\fR. .SH "MAINTAINERS" .IX Header "MAINTAINERS" .IP "Chad Granum <exodist@cpan.org>" 4 .IX Item "Chad Granum <exodist@cpan.org>" .SH "AUTHORS" .IX Header "AUTHORS" .PD 0 .IP "Chad Granum <exodist@cpan.org>" 4 .IX Item "Chad Granum <exodist@cpan.org>" .PD .SH "COPYRIGHT" .IX Header "COPYRIGHT" Copyright 2020 Chad Granum <exodist@cpan.org>. .PP This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. .PP See \fIhttp://dev.perl.org/licenses/\fR
Close