f7b79b51da9fb3ca02e6b9e38efc0db1a4c05fdd
[pkg-perl] / deb-src / libperl-critic-perl / libperl-critic-perl-1.088 / t / Modules / RequireNoMatchVarsWithUseEnglish.run
1 ## name Passing with no "use English".
2 ## failures 0
3 ## cut
4
5 use strict;
6 use warnings;
7
8 my $doodle_doodle_dee = 'wubba wubba wubba';
9
10 #-----------------------------------------------------------------------------
11
12 ## name Passing single quotes.
13 ## failures 0
14 ## cut
15
16 use English '-no_match_vars';
17
18 #-----------------------------------------------------------------------------
19
20 ## name Passing double quotes
21 ## failures 0
22 ## cut
23
24 use English "-no_match_vars";
25
26 #-----------------------------------------------------------------------------
27
28 ## name Passing literal quotes.
29 ## failures 0
30 ## cut
31
32 use English q/-no_match_vars/;
33 use English q{-no_match_vars};
34 use English q(-no_match_vars);
35 use English q[-no_match_vars];
36 use English q<-no_match_vars>;
37 use English q!-no_match_vars!;
38 use English q#-no_match_vars#;
39 use English q'-no_match_vars';
40 use English q"-no_match_vars";
41
42 #-----------------------------------------------------------------------------
43
44 ## name Passing literal quotes with whitespace before delimiter.
45 ## failures 0
46 ## cut
47
48 use English q              /-no_match_vars/;
49 use English q              {-no_match_vars};
50 use English q              (-no_match_vars);
51 use English q              [-no_match_vars];
52 use English q              <-no_match_vars>;
53 use English q              !-no_match_vars!;
54 use English q              '-no_match_vars';
55 use English q              "-no_match_vars";
56
57 #-----------------------------------------------------------------------------
58
59 ## name Passing interpolating quotes.
60 ## failures 0
61 ## cut
62
63 use English qq/-no_match_vars/;
64 use English qq{-no_match_vars};
65 use English qq(-no_match_vars);
66 use English qq[-no_match_vars];
67 use English qq<-no_match_vars>;
68 use English qq!-no_match_vars!;
69 use English qq#-no_match_vars#;
70 use English qq'-no_match_vars';
71 use English qq"-no_match_vars";
72
73 #-----------------------------------------------------------------------------
74
75 ## name Passing interpolating quotes with whitespace before delimiter.
76 ## failures 0
77 ## cut
78
79 use English qq             /-no_match_vars/;
80 use English qq             {-no_match_vars};
81 use English qq             (-no_match_vars);
82 use English qq             [-no_match_vars];
83 use English qq             <-no_match_vars>;
84 use English qq             !-no_match_vars!;
85 use English qq             '-no_match_vars';
86 use English qq             "-no_match_vars";
87
88 #-----------------------------------------------------------------------------
89
90 ## name Passing quotelike words.
91 ## failures 0
92 ## cut
93
94 use English qw/  -no_match_vars  /;
95 use English qw{  -no_match_vars  };
96 use English qw(  -no_match_vars  );
97 use English qw[  -no_match_vars  ];
98 use English qw<  -no_match_vars  >;
99 use English qw!  -no_match_vars  !;
100 use English qw#  -no_match_vars  #;
101 use English qw'  -no_match_vars  ';
102 use English qw"  -no_match_vars  ";
103
104 #-----------------------------------------------------------------------------
105
106 ## name Passing quotelike words with whitespace before delimiter.
107 ## failures 0
108 ## cut
109
110 use English qw            /  -no_match_vars  /;
111 use English qw            {  -no_match_vars  };
112 use English qw            (  -no_match_vars  );
113 use English qw            [  -no_match_vars  ];
114 use English qw            <  -no_match_vars  >;
115 use English qw            !  -no_match_vars  !;
116 use English qw            '  -no_match_vars  ';
117 use English qw            "  -no_match_vars  ";
118
119 #-----------------------------------------------------------------------------
120
121 ## name Passing quotelike words with things in addition to -no_match_vars.
122 ## failures 0
123 ## cut
124
125 use English qw/ $ERRNO -no_match_vars $EVAL_ERROR /;
126
127 #-----------------------------------------------------------------------------
128
129 ## name Passing parenthesized list.
130 ## failures 0
131 ## cut
132
133 use English ( '-no_match_vars' );
134
135 #-----------------------------------------------------------------------------
136
137 ## name Passing parenthesized list with things in addition to -no_match_vars.
138 ## failures 0
139 ## cut
140
141 use English ( '$ERRNO', "-no_match_vars", "$EVAL_ERROR" );
142
143 #-----------------------------------------------------------------------------
144
145 ## name Passing unparenthesized list with things in addition to -no_match_vars.
146 ## failures 0
147 ## cut
148
149 use English '$ERRNO', "-no_match_vars", "$EVAL_ERROR";
150
151 #-----------------------------------------------------------------------------
152
153 ## name Passing version.
154 ## failures 0
155 ## cut
156
157 use English 1.02 '-no_match_vars';
158
159 #-----------------------------------------------------------------------------
160
161 ## name Passing v-string version.
162 ## failures 0
163 ## cut
164
165 use English v1.02 '-no_match_vars';
166
167 #-----------------------------------------------------------------------------
168
169 ## name Passing parenthesized list and version.
170 ## failures 0
171 ## cut
172
173 use English 1.02 ('-no_match_vars');
174
175 #-----------------------------------------------------------------------------
176
177 ## name Basic failure.
178 ## failures 1
179 ## cut
180
181 use English;
182
183 #-----------------------------------------------------------------------------
184
185 ## name Failure with version.
186 ## failures 1
187 ## cut
188
189 use English 1.02;
190
191 #-----------------------------------------------------------------------------
192
193 ## name Failure with v-string.
194 ## failures 1
195 ## cut
196
197 use English v1.02;
198
199 #-----------------------------------------------------------------------------
200
201 ## name Failure with random garbage.
202 ## failures 2
203 ## cut
204
205 use English 'oink oink';
206 use English qw< blah blah blah >;
207
208 #-----------------------------------------------------------------------------
209
210 ## name Failure with typo that Ovid noticed.
211 ## failures 1
212 ## cut
213
214 use English qw(-no_mactch_vars);
215
216 #-----------------------------------------------------------------------------
217
218 ##############################################################################
219 #      $URL: http://perlcritic.tigris.org/svn/perlcritic/trunk/Perl-Critic/t/Modules/RequireNoMatchVarsWithUseEnglish.run $
220 #     $Date: 2008-03-16 17:40:45 -0500 (Sun, 16 Mar 2008) $
221 #   $Author: clonezone $
222 # $Revision: 2187 $
223 ##############################################################################
224
225 # Local Variables:
226 #   mode: cperl
227 #   cperl-indent-level: 4
228 #   fill-column: 78
229 #   indent-tabs-mode: nil
230 #   c-indentation-style: bsd
231 # End:
232 # ex: set ts=8 sts=4 sw=4 tw=78 ft=perl expandtab shiftround :