1Test::RunValgrind(3)  User Contributed Perl Documentation Test::RunValgrind(3)
2
3
4

NAME

6       Test::RunValgrind - tests that an external program is valgrind-clean.
7

VERSION

9       version 0.2.1
10

SYNOPSIS

12           use Test::More tests => 1;
13           use Test::RunValgrind;
14
15           # TEST
16           Test::RunValgrind->new( {} )->run(
17               {
18                   log_fn => './expr--valgrind-log.txt',
19                   prog   => '/usr/bin/expr',
20                   argv   => [qw/5 + 6/],
21                   blurb  => 'valgrind likes /usr/bin/expr',
22               }
23           );
24

DESCRIPTION

26       valgrind is an open source and convenient memory debugger that runs on
27       some platforms. This module runs valgrind
28       (<http://en.wikipedia.org/wiki/Valgrind>) on an executable and makes
29       sure that valgrind did not find any faults in it.
30
31       It originated from some code used to test the Freecell Solver
32       executables using valgrind, and was extracted into its own CPAN module
33       to allow for reuse by other projects, including fortune-mod
34       (<https://github.com/shlomif/fortune-mod>).
35

VERSION

37       version 0.2.1
38

METHODS

40   my $obj = Test::RunValgrind->new({})
41       The constructor - currently accepts a single hash reference and if its
42       'supress_stderr' key's value is true, supresses outputting STDERR if on
43       successful subsequent tests (starting from version 0.0.2).  Furthermore
44       if 'ignore_leaks' is true, then reported memory leaks are ignored and
45       their presence will still allow the tests to pass (starting from
46       version 0.2.0, and see
47       <https://rt.cpan.org/Public/Bug/Display.html?id=119988> ).
48
49       'valgrind_args' may point to an array reference of extra command line
50       arguments to valgrind.  See
51       <https://github.com/shlomif/perl-Test-RunValgrind/issues/4> ; since
52       version 0.2.0.
53
54   $obj->run({ ... })
55       Runs valgrind.
56
57       Accepts a hash ref with the following keys:
58
59       ·   blurb
60
61           The Test::More test assertion blurb.
62
63       ·   log_fn
64
65           The path to write the log file to (and read from it). Make sure it
66           is secured.
67
68       ·   prog
69
70           The path to the executable to run.
71
72       ·   argv
73
74           An array reference contains strings with command line arguments to
75           the executable.
76
77       See the synopsis for an example.
78

SEE ALSO

80       Test::Valgrind - seems to be only for running perl itself under
81       valgrind.
82
83       Devel::Valgrind::Client
84
85       <http://en.wikipedia.org/wiki/Valgrind> - wikipedia page.
86
87       <http://github.com/shlomif/fc-solve/blob/master/fc-solve/source/t/t/lib/FC_Solve/Test/Valgrind.pm>
88       - original code using Test::RunValgrind in Freecell Solver
89

AUTHOR

91       Shlomi Fish <shlomif@cpan.org>
92
94       This software is Copyright (c) 2016 by Shlomi Fish.
95
96       This is free software, licensed under:
97
98         The MIT (X11) License
99

BUGS

101       Please report any bugs or feature requests on the bugtracker website
102       <https://github.com/shlomif/perl-Test-RunValgrind/issues>
103
104       When submitting a bug or request, please include a test-file or a patch
105       to an existing test-file that illustrates the bug or desired feature.
106

SUPPORT

108   Perldoc
109       You can find documentation for this module with the perldoc command.
110
111         perldoc Test::RunValgrind
112
113   Websites
114       The following websites have more information about this module, and may
115       be of help to you. As always, in addition to those websites please use
116       your favorite search engine to discover more resources.
117
118       ·   MetaCPAN
119
120           A modern, open-source CPAN search engine, useful to view POD in
121           HTML format.
122
123           <https://metacpan.org/release/Test-RunValgrind>
124
125       ·   Search CPAN
126
127           The default CPAN search engine, useful to view POD in HTML format.
128
129           <http://search.cpan.org/dist/Test-RunValgrind>
130
131       ·   RT: CPAN's Bug Tracker
132
133           The RT ( Request Tracker ) website is the default bug/issue
134           tracking system for CPAN.
135
136           <https://rt.cpan.org/Public/Dist/Display.html?Name=Test-RunValgrind>
137
138       ·   AnnoCPAN
139
140           The AnnoCPAN is a website that allows community annotations of Perl
141           module documentation.
142
143           <http://annocpan.org/dist/Test-RunValgrind>
144
145       ·   CPAN Ratings
146
147           The CPAN Ratings is a website that allows community ratings and
148           reviews of Perl modules.
149
150           <http://cpanratings.perl.org/d/Test-RunValgrind>
151
152       ·   CPANTS
153
154           The CPANTS is a website that analyzes the Kwalitee ( code metrics )
155           of a distribution.
156
157           <http://cpants.cpanauthors.org/dist/Test-RunValgrind>
158
159       ·   CPAN Testers
160
161           The CPAN Testers is a network of smoke testers who run automated
162           tests on uploaded CPAN distributions.
163
164           <http://www.cpantesters.org/distro/T/Test-RunValgrind>
165
166       ·   CPAN Testers Matrix
167
168           The CPAN Testers Matrix is a website that provides a visual
169           overview of the test results for a distribution on various
170           Perls/platforms.
171
172           <http://matrix.cpantesters.org/?dist=Test-RunValgrind>
173
174       ·   CPAN Testers Dependencies
175
176           The CPAN Testers Dependencies is a website that shows a chart of
177           the test results of all dependencies for a distribution.
178
179           <http://deps.cpantesters.org/?module=Test::RunValgrind>
180
181   Bugs / Feature Requests
182       Please report any bugs or feature requests by email to
183       "bug-test-runvalgrind at rt.cpan.org", or through the web interface at
184       <https://rt.cpan.org/Public/Bug/Report.html?Queue=Test-RunValgrind>.
185       You will be automatically notified of any progress on the request by
186       the system.
187
188   Source Code
189       The code is open to the world, and available for you to hack on. Please
190       feel free to browse it and play with it, or whatever. If you want to
191       contribute patches, please send me a diff or prod me to pull from your
192       repository :)
193
194       <https://github.com/shlomif/perl-Test-RunValgrind>
195
196         git clone git://github.com/shlomif/perl-Test-RunValgrind.git
197
198
199
200perl v5.32.0                      2020-07-28              Test::RunValgrind(3)
Impressum