1Test::Stream::DebugInfoU(s3e)r Contributed Perl DocumentaTteisotn::Stream::DebugInfo(3)
2
3
4

NAME

6       Test::Stream::DebugInfo - Debug information for events
7

DEPRECATED

9       This distribution is deprecated in favor of Test2, Test2::Suite, and
10       Test2::Workflow.
11
12       See Test::Stream::Manual::ToTest2 for a conversion guide.
13

DESCRIPTION

15       All events need to have access to information about where they were
16       created, as well as if they are todo, or part of a skipped test. This
17       object represents that information.
18

SYNOPSIS

20           use Test::Stream::DebugInfo;
21
22           my $dbg = Test::Stream::DebugInfo->new(
23               frame => [$package, $file, $line, $subname],
24           );
25

METHODS

27       $dbg->set_todo($reason)
28       $reason = $dbg->todo
29           Get/Set/Unset todo for the current debug-info.
30
31       $dbg->set_skip($reason)
32       $reason = $dbg->skip
33           Get/Set/Unset skip for the current debug-info.
34
35       $dbg->set_detail($msg)
36       $msg = $dbg->detail
37           Used to get/set a custom trace message that will be used INSTEAD of
38           "at <FILE> line <LINE>" when calling "$dbg->trace".
39
40       $dbg->trace
41           Typically returns the string "at <FILE> line <LINE>". If "detail"
42           is set then its value wil be returned instead.
43
44       $dbg->alert($MESSAGE)
45           This issues a warning at the frame (filename and line number where
46           errors should be reported).
47
48       $dbg->throw($MESSAGE)
49           This throws an exception at the frame (filename and line number
50           where errors should be reported).
51
52       $frame = $dbg->frame()
53           Get the call frame arrayref.
54
55       ($package, $file, $line, $subname) = $dbg->call()
56           Get the caller details for the debug-info. This is where errors
57           should be reported.
58
59       $pkg = $dbg->package
60           Get the debug-info package.
61
62       $file = $dbg->file
63           Get the debug-info filename.
64
65       $line = $dbg->line
66           Get the debug-info line number.
67
68       $subname = $dbg->subname
69           Get the debug-info subroutine name.
70

SOURCE

72       The source code repository for Test::Stream can be found at
73       http://github.com/Test-More/Test-Stream/.
74

MAINTAINERS

76       Chad Granum <exodist@cpan.org>
77

AUTHORS

79       Chad Granum <exodist@cpan.org>
80
82       Copyright 2015 Chad Granum <exodist7@gmail.com>.
83
84       This program is free software; you can redistribute it and/or modify it
85       under the same terms as Perl itself.
86
87       See http://dev.perl.org/licenses/
88
89
90
91perl v5.32.1                      2021-01-27        Test::Stream::DebugInfo(3)
Impressum