1Dist::Zilla::Plugin::TeUsste:r:CCoomnptirlieb(u3tpemd)PDeirslt:D:oZciulmlean:t:aPtliuognin::Test::Compile(3pm)
2
3
4

NAME

6       Dist::Zilla::Plugin::Test::Compile - Common tests to check syntax of
7       your modules, using only core modules
8

VERSION

10       version 2.058
11

SYNOPSIS

13       In your dist.ini:
14
15           [Test::Compile]
16           skip      = Test$
17           fake_home = 1
18           needs_display = 1
19           fail_on_warning = author
20           bail_out_on_fail = 1
21           switch = -M-warnings=numeric    ; like "no warnings 'numeric'
22

DESCRIPTION

24       This is a Dist::Zilla plugin that runs at the gather files stage,
25       providing a test file (configurable, defaulting to t/00-compile.t).
26
27       This test will find all modules and scripts in your distribution, and
28       try to compile them one by one. This means it's a bit slower than
29       loading them all at once, but it will catch more errors.
30
31       The generated test is guaranteed to only depend on modules that are
32       available in core.  Most options only require perl 5.6.2; the
33       "bail_out_on_fail" option requires the version of Test::More that
34       shipped with perl 5.12 (but the test still runs on perl 5.6).
35
36       This plugin accepts the following options:
37

CONFIGURATION OPTIONS

39   "filename"
40       The name of the generated file. Defaults to t/00-compile.t
41
42   "phase"
43       The phase for which to register prerequisites. Defaults to "test".
44       Setting this to a false value will disable prerequisite registration.
45
46   "skip"
47       A regex to skip compile test for modules matching it. The match is done
48       against the module name ("Foo::Bar"), not the file path
49       (lib/Foo/Bar.pm).  This option can be repeated to specify multiple
50       regexes.
51
52   "file"
53       A filename to also test, in addition to any files found earlier.  It
54       will be tested as a module if it ends with ".pm" or ".PM", and as a
55       script otherwise.  Module filenames should be relative to lib; others
56       should be relative to the base of the repository.  This option can be
57       repeated to specify multiple additional files.
58
59   "fake_home"
60       A boolean to indicate whether to fake $ENV{HOME}.  This may be needed
61       if your module unilaterally creates stuff in the user's home directory:
62       indeed, some cpantesters will smoke test your distribution with a read-
63       only home directory. Defaults to false.
64
65   "needs_display"
66       A boolean to indicate whether to skip the compile test on non-Win32
67       systems when $ENV{DISPLAY} is not set. Defaults to false.
68
69   "fail_on_warning"
70       A string to indicate when to add a test for warnings during compilation
71       checks. Possible values are:
72
73       •   "none": do not test for warnings
74
75       •   "author": test for warnings only when AUTHOR_TESTING is set
76           (default, and recommended)
77
78       •   "all": always test for warnings (not recommended, as this can
79           prevent installation of modules when upstream dependencies exhibit
80           warnings in a new Perl release)
81
82   "bail_out_on_fail"
83       A boolean to indicate whether the test will BAIL_OUT of all subsequent
84       tests when compilation failures are encountered. Defaults to false.
85
86   "module_finder"
87       This is the name of a FileFinder for finding modules to check.  The
88       default value is ":InstallModules"; this option can be used more than
89       once.  .pod files are always skipped.
90
91       Other predefined finders are listed in "default_finders" in
92       Dist::Zilla::Role::FileFinderUser.  You can define your own with the
93       [FileFinder::ByName] and [FileFinder::Filter] plugins.
94
95   "script_finder"
96       Just like "module_finder", but for finding scripts.  The default value
97       is ":PerlExecFiles" (when available; otherwise ":ExecFiles") -- see
98       also Dist::Zilla::Plugin::ExecDir, to make sure these files are
99       properly marked as executables for the installer.
100
101   "xt_mode"
102       When true, the default "filename" becomes xt/author/00-compile.t and
103       the default "dependency" phase becomes "develop".
104
105   "switch"
106       Use this option to pass a command-line switch (e.g. "-d:Confess",
107       "-M-warnings=numeric") to the command that tests the module or script.
108       Can be used more than once.  See perlrun for more on constructing these
109       switches.
110

RUNTIME ENVIRONMENT OPTIONS

112       If the environment variable $PERL_COMPILE_TEST_DEBUG is set to a true
113       option when the test is run, the command to test each file will be
114       printed as a "diag".
115

SEE ALSO

117       •   Test::NeedsDisplay
118
119       •   Test::Script
120

SUPPORT

122       Bugs may be submitted through the RT bug tracker
123       <https://rt.cpan.org/Public/Dist/Display.html?Name=Dist-Zilla-Plugin-
124       Test-Compile> (or bug-Dist-Zilla-Plugin-Test-Compile@rt.cpan.org
125       <mailto:bug-Dist-Zilla-Plugin-Test-Compile@rt.cpan.org>).
126
127       There is also a mailing list available for users of this distribution,
128       at <http://dzil.org/#mailing-list>.
129
130       There is also an irc channel available for users of this distribution,
131       at "#distzilla" on "irc.perl.org" <irc://irc.perl.org/#distzilla>.
132

AUTHORS

134       •   Jérôme Quelin <jquelin@gmail.com>
135
136       •   Karen Etheridge <ether@cpan.org>
137

CONTRIBUTORS

139       •   Ahmad M. Zawawi <ahmad.zawawi@gmail.com>
140
141       •   Olivier Mengué <dolmen@cpan.org>
142
143       •   Kent Fredric <kentnl@cpan.org>
144
145       •   Jesse Luehrs <doy@tozt.net>
146
147       •   David Golden <dagolden@cpan.org>
148
149       •   Randy Stauner <rwstauner@cpan.org>
150
151       •   Harley Pig <harleypig@gmail.com>
152
153       •   Graham Knop <haarg@haarg.org>
154
155       •   fayland <fayland@gmail.com>
156
157       •   Peter Shangov <pshangov@yahoo.com>
158
159       •   Chris Weyl <cweyl@alumni.drew.edu>
160
161       •   Ricardo SIGNES <rjbs@cpan.org>
162
163       •   Marcel Gruenauer <hanekomu@gmail.com>
164
166       This software is copyright (c) 2009 by Jérôme Quelin.
167
168       This is free software; you can redistribute it and/or modify it under
169       the same terms as the Perl 5 programming language system itself.
170
171
172
173perl v5.36.0                      2023-0D1i-s2t0::Zilla::Plugin::Test::Compile(3pm)
Impressum