line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Dist::Zilla::App::Command::smoke 6.030; |
2
|
|
|
|
|
|
|
# ABSTRACT: smoke your dist |
3
|
|
|
|
|
|
|
|
4
|
4
|
|
|
4
|
|
2892
|
use Dist::Zilla::Pragmas; |
|
4
|
|
|
|
|
12
|
|
|
4
|
|
|
|
|
28
|
|
5
|
|
|
|
|
|
|
|
6
|
4
|
|
|
4
|
|
36
|
use Dist::Zilla::App -command; |
|
4
|
|
|
|
|
8
|
|
|
4
|
|
|
|
|
41
|
|
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
#pod =head1 SYNOPSIS |
9
|
|
|
|
|
|
|
#pod |
10
|
|
|
|
|
|
|
#pod dzil smoke [ --release ] [ --author ] [ --no-automated ] |
11
|
|
|
|
|
|
|
#pod |
12
|
|
|
|
|
|
|
#pod =head1 DESCRIPTION |
13
|
|
|
|
|
|
|
#pod |
14
|
|
|
|
|
|
|
#pod This command builds and tests the distribution in "smoke testing mode." |
15
|
|
|
|
|
|
|
#pod |
16
|
|
|
|
|
|
|
#pod This command is a thin wrapper around the L<test|Dist::Zilla::Dist::Builder/test> method in |
17
|
|
|
|
|
|
|
#pod Dist::Zilla. It builds your dist and runs the tests with the AUTOMATED_TESTING |
18
|
|
|
|
|
|
|
#pod environment variable turned on, so it's like doing this: |
19
|
|
|
|
|
|
|
#pod |
20
|
|
|
|
|
|
|
#pod export AUTOMATED_TESTING=1 |
21
|
|
|
|
|
|
|
#pod dzil build --no-tgz |
22
|
|
|
|
|
|
|
#pod cd $BUILD_DIRECTORY |
23
|
|
|
|
|
|
|
#pod perl Makefile.PL |
24
|
|
|
|
|
|
|
#pod make |
25
|
|
|
|
|
|
|
#pod make test |
26
|
|
|
|
|
|
|
#pod |
27
|
|
|
|
|
|
|
#pod A build that fails tests will be left behind for analysis, and F<dzil> will |
28
|
|
|
|
|
|
|
#pod exit a non-zero value. If the tests are successful, the build directory will |
29
|
|
|
|
|
|
|
#pod be removed and F<dzil> will exit with status 0. |
30
|
|
|
|
|
|
|
#pod |
31
|
|
|
|
|
|
|
#pod =cut |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
sub opt_spec { |
34
|
0
|
|
|
0
|
1
|
|
[ 'release' => 'enables the RELEASE_TESTING env variable', { default => 0 } ], |
35
|
|
|
|
|
|
|
[ 'automated!' => 'enables the AUTOMATED_TESTING env variable (default behavior)', { default => 1 } ], |
36
|
|
|
|
|
|
|
[ 'author' => 'enables the AUTHOR_TESTING env variable', { default => 0 } ] |
37
|
|
|
|
|
|
|
} |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
#pod =head1 OPTIONS |
40
|
|
|
|
|
|
|
#pod |
41
|
|
|
|
|
|
|
#pod =head2 --release |
42
|
|
|
|
|
|
|
#pod |
43
|
|
|
|
|
|
|
#pod This will run the test suite with RELEASE_TESTING=1 |
44
|
|
|
|
|
|
|
#pod |
45
|
|
|
|
|
|
|
#pod =head2 --no-automated |
46
|
|
|
|
|
|
|
#pod |
47
|
|
|
|
|
|
|
#pod This will run the test suite without setting AUTOMATED_TESTING |
48
|
|
|
|
|
|
|
#pod |
49
|
|
|
|
|
|
|
#pod =head2 --author |
50
|
|
|
|
|
|
|
#pod |
51
|
|
|
|
|
|
|
#pod This will run the test suite with AUTHOR_TESTING=1 |
52
|
|
|
|
|
|
|
#pod |
53
|
|
|
|
|
|
|
#pod =cut |
54
|
|
|
|
|
|
|
|
55
|
0
|
|
|
0
|
1
|
|
sub abstract { 'smoke your dist' } |
56
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
sub execute { |
58
|
0
|
|
|
0
|
1
|
|
my ($self, $opt, $arg) = @_; |
59
|
|
|
|
|
|
|
|
60
|
0
|
0
|
|
|
|
|
local $ENV{RELEASE_TESTING} = 1 if $opt->release; |
61
|
0
|
0
|
|
|
|
|
local $ENV{AUTHOR_TESTING} = 1 if $opt->author; |
62
|
0
|
0
|
|
|
|
|
local $ENV{AUTOMATED_TESTING} = 1 if $opt->automated; |
63
|
|
|
|
|
|
|
|
64
|
0
|
|
|
|
|
|
$self->zilla->test; |
65
|
|
|
|
|
|
|
} |
66
|
|
|
|
|
|
|
|
67
|
|
|
|
|
|
|
1; |
68
|
|
|
|
|
|
|
|
69
|
|
|
|
|
|
|
__END__ |
70
|
|
|
|
|
|
|
|
71
|
|
|
|
|
|
|
=pod |
72
|
|
|
|
|
|
|
|
73
|
|
|
|
|
|
|
=encoding UTF-8 |
74
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
=head1 NAME |
76
|
|
|
|
|
|
|
|
77
|
|
|
|
|
|
|
Dist::Zilla::App::Command::smoke - smoke your dist |
78
|
|
|
|
|
|
|
|
79
|
|
|
|
|
|
|
=head1 VERSION |
80
|
|
|
|
|
|
|
|
81
|
|
|
|
|
|
|
version 6.030 |
82
|
|
|
|
|
|
|
|
83
|
|
|
|
|
|
|
=head1 SYNOPSIS |
84
|
|
|
|
|
|
|
|
85
|
|
|
|
|
|
|
dzil smoke [ --release ] [ --author ] [ --no-automated ] |
86
|
|
|
|
|
|
|
|
87
|
|
|
|
|
|
|
=head1 DESCRIPTION |
88
|
|
|
|
|
|
|
|
89
|
|
|
|
|
|
|
This command builds and tests the distribution in "smoke testing mode." |
90
|
|
|
|
|
|
|
|
91
|
|
|
|
|
|
|
This command is a thin wrapper around the L<test|Dist::Zilla::Dist::Builder/test> method in |
92
|
|
|
|
|
|
|
Dist::Zilla. It builds your dist and runs the tests with the AUTOMATED_TESTING |
93
|
|
|
|
|
|
|
environment variable turned on, so it's like doing this: |
94
|
|
|
|
|
|
|
|
95
|
|
|
|
|
|
|
export AUTOMATED_TESTING=1 |
96
|
|
|
|
|
|
|
dzil build --no-tgz |
97
|
|
|
|
|
|
|
cd $BUILD_DIRECTORY |
98
|
|
|
|
|
|
|
perl Makefile.PL |
99
|
|
|
|
|
|
|
make |
100
|
|
|
|
|
|
|
make test |
101
|
|
|
|
|
|
|
|
102
|
|
|
|
|
|
|
A build that fails tests will be left behind for analysis, and F<dzil> will |
103
|
|
|
|
|
|
|
exit a non-zero value. If the tests are successful, the build directory will |
104
|
|
|
|
|
|
|
be removed and F<dzil> will exit with status 0. |
105
|
|
|
|
|
|
|
|
106
|
|
|
|
|
|
|
=head1 PERL VERSION |
107
|
|
|
|
|
|
|
|
108
|
|
|
|
|
|
|
This module should work on any version of perl still receiving updates from |
109
|
|
|
|
|
|
|
the Perl 5 Porters. This means it should work on any version of perl released |
110
|
|
|
|
|
|
|
in the last two to three years. (That is, if the most recently released |
111
|
|
|
|
|
|
|
version is v5.40, then this module should work on both v5.40 and v5.38.) |
112
|
|
|
|
|
|
|
|
113
|
|
|
|
|
|
|
Although it may work on older versions of perl, no guarantee is made that the |
114
|
|
|
|
|
|
|
minimum required version will not be increased. The version may be increased |
115
|
|
|
|
|
|
|
for any reason, and there is no promise that patches will be accepted to lower |
116
|
|
|
|
|
|
|
the minimum required perl. |
117
|
|
|
|
|
|
|
|
118
|
|
|
|
|
|
|
=head1 OPTIONS |
119
|
|
|
|
|
|
|
|
120
|
|
|
|
|
|
|
=head2 --release |
121
|
|
|
|
|
|
|
|
122
|
|
|
|
|
|
|
This will run the test suite with RELEASE_TESTING=1 |
123
|
|
|
|
|
|
|
|
124
|
|
|
|
|
|
|
=head2 --no-automated |
125
|
|
|
|
|
|
|
|
126
|
|
|
|
|
|
|
This will run the test suite without setting AUTOMATED_TESTING |
127
|
|
|
|
|
|
|
|
128
|
|
|
|
|
|
|
=head2 --author |
129
|
|
|
|
|
|
|
|
130
|
|
|
|
|
|
|
This will run the test suite with AUTHOR_TESTING=1 |
131
|
|
|
|
|
|
|
|
132
|
|
|
|
|
|
|
=head1 AUTHOR |
133
|
|
|
|
|
|
|
|
134
|
|
|
|
|
|
|
Ricardo SIGNES 😏 <cpan@semiotic.systems> |
135
|
|
|
|
|
|
|
|
136
|
|
|
|
|
|
|
=head1 COPYRIGHT AND LICENSE |
137
|
|
|
|
|
|
|
|
138
|
|
|
|
|
|
|
This software is copyright (c) 2023 by Ricardo SIGNES. |
139
|
|
|
|
|
|
|
|
140
|
|
|
|
|
|
|
This is free software; you can redistribute it and/or modify it under |
141
|
|
|
|
|
|
|
the same terms as the Perl 5 programming language system itself. |
142
|
|
|
|
|
|
|
|
143
|
|
|
|
|
|
|
=cut |