puppetlabs_spec_helper 1.1.1 → 1.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +9 -0
- data/.rspec +2 -0
- data/.rubocop.yml +504 -0
- data/.travis.yml +17 -6
- data/CHANGELOG.md +47 -3
- data/CONTRIBUTING.md +5 -46
- data/Gemfile +15 -9
- data/{README.markdown → README.md} +185 -64
- data/Rakefile +5 -40
- data/lib/puppetlabs_spec_helper/module_spec_helper.rb +2 -8
- data/lib/puppetlabs_spec_helper/puppetlabs_spec/puppet_internals.rb +2 -0
- data/lib/puppetlabs_spec_helper/rake_tasks.rb +153 -22
- data/lib/puppetlabs_spec_helper/version.rb +4 -1
- data/puppetlabs_spec_helper.gemspec +27 -83
- metadata +69 -58
- data/spec/lib/puppet/type/spechelper.rb +0 -6
- data/spec/spec_helper.rb +0 -2
- data/spec/unit/puppetlabs_spec_helper/puppetlabs_spec/puppet_internals_spec.rb +0 -91
- data/spec/watchr.rb +0 -79
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: cc3386df61b1fedabba7e20fcbf2d7e19d588210
|
4
|
+
data.tar.gz: c892ab82a4647c84f728f31ed22c49b2821c7ea8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 35f46e0d7db0fad995e00e8f6e7ea029f4fc91c1a187855eb1d76a27d1ef898a2fcf6daa713260f792ad1aace5bd6d169abece553f9c612ce521c3ef5fb64436
|
7
|
+
data.tar.gz: 366b7962fd0794271799a36c29889a502af326099ad410546f730f8d87786a26608842f719f16a7cfb03d8caec5730f3e2f25bfa9d47d044eac27579843a6787
|
data/.gitignore
ADDED
data/.rspec
ADDED
data/.rubocop.yml
ADDED
@@ -0,0 +1,504 @@
|
|
1
|
+
require: rubocop-rspec
|
2
|
+
AllCops:
|
3
|
+
TargetRubyVersion: 1.9
|
4
|
+
Include:
|
5
|
+
- ./**/*.rb
|
6
|
+
|
7
|
+
Lint/ConditionPosition:
|
8
|
+
Enabled: True
|
9
|
+
|
10
|
+
Lint/ElseLayout:
|
11
|
+
Enabled: True
|
12
|
+
|
13
|
+
Lint/UnreachableCode:
|
14
|
+
Enabled: True
|
15
|
+
|
16
|
+
Lint/UselessComparison:
|
17
|
+
Enabled: True
|
18
|
+
|
19
|
+
Lint/EnsureReturn:
|
20
|
+
Enabled: True
|
21
|
+
|
22
|
+
Lint/HandleExceptions:
|
23
|
+
Enabled: True
|
24
|
+
|
25
|
+
Lint/LiteralInCondition:
|
26
|
+
Enabled: True
|
27
|
+
|
28
|
+
Lint/ShadowingOuterLocalVariable:
|
29
|
+
Enabled: True
|
30
|
+
|
31
|
+
Lint/LiteralInInterpolation:
|
32
|
+
Enabled: True
|
33
|
+
|
34
|
+
Style/HashSyntax:
|
35
|
+
Enabled: True
|
36
|
+
|
37
|
+
Style/RedundantReturn:
|
38
|
+
Enabled: True
|
39
|
+
|
40
|
+
Lint/AmbiguousOperator:
|
41
|
+
Enabled: True
|
42
|
+
|
43
|
+
Lint/AssignmentInCondition:
|
44
|
+
Enabled: True
|
45
|
+
|
46
|
+
Style/SpaceBeforeComment:
|
47
|
+
Enabled: True
|
48
|
+
|
49
|
+
Style/AndOr:
|
50
|
+
Enabled: True
|
51
|
+
|
52
|
+
Style/RedundantSelf:
|
53
|
+
Enabled: True
|
54
|
+
|
55
|
+
# Method length is not necessarily an indicator of code quality
|
56
|
+
Metrics/MethodLength:
|
57
|
+
Enabled: False
|
58
|
+
|
59
|
+
# Module length is not necessarily an indicator of code quality
|
60
|
+
Metrics/ModuleLength:
|
61
|
+
Enabled: False
|
62
|
+
|
63
|
+
Style/WhileUntilModifier:
|
64
|
+
Enabled: True
|
65
|
+
|
66
|
+
Lint/AmbiguousRegexpLiteral:
|
67
|
+
Enabled: True
|
68
|
+
|
69
|
+
Lint/Eval:
|
70
|
+
Enabled: True
|
71
|
+
|
72
|
+
Lint/BlockAlignment:
|
73
|
+
Enabled: True
|
74
|
+
|
75
|
+
Lint/DefEndAlignment:
|
76
|
+
Enabled: True
|
77
|
+
|
78
|
+
Lint/EndAlignment:
|
79
|
+
Enabled: True
|
80
|
+
|
81
|
+
Lint/DeprecatedClassMethods:
|
82
|
+
Enabled: True
|
83
|
+
|
84
|
+
Lint/Loop:
|
85
|
+
Enabled: True
|
86
|
+
|
87
|
+
Lint/ParenthesesAsGroupedExpression:
|
88
|
+
Enabled: True
|
89
|
+
|
90
|
+
Lint/RescueException:
|
91
|
+
Enabled: True
|
92
|
+
|
93
|
+
Lint/StringConversionInInterpolation:
|
94
|
+
Enabled: True
|
95
|
+
|
96
|
+
Lint/UnusedBlockArgument:
|
97
|
+
Enabled: True
|
98
|
+
|
99
|
+
Lint/UnusedMethodArgument:
|
100
|
+
Enabled: True
|
101
|
+
|
102
|
+
Lint/UselessAccessModifier:
|
103
|
+
Enabled: True
|
104
|
+
|
105
|
+
Lint/UselessAssignment:
|
106
|
+
Enabled: True
|
107
|
+
|
108
|
+
Lint/Void:
|
109
|
+
Enabled: True
|
110
|
+
|
111
|
+
Style/AccessModifierIndentation:
|
112
|
+
Enabled: True
|
113
|
+
|
114
|
+
Style/AccessorMethodName:
|
115
|
+
Enabled: True
|
116
|
+
|
117
|
+
Style/Alias:
|
118
|
+
Enabled: True
|
119
|
+
|
120
|
+
Style/AlignArray:
|
121
|
+
Enabled: True
|
122
|
+
|
123
|
+
Style/AlignHash:
|
124
|
+
Enabled: True
|
125
|
+
|
126
|
+
Style/AlignParameters:
|
127
|
+
Enabled: True
|
128
|
+
|
129
|
+
Metrics/BlockNesting:
|
130
|
+
Enabled: True
|
131
|
+
|
132
|
+
Style/AsciiComments:
|
133
|
+
Enabled: True
|
134
|
+
|
135
|
+
Style/Attr:
|
136
|
+
Enabled: True
|
137
|
+
|
138
|
+
Style/BracesAroundHashParameters:
|
139
|
+
Enabled: True
|
140
|
+
|
141
|
+
Style/CaseEquality:
|
142
|
+
Enabled: True
|
143
|
+
|
144
|
+
Style/CaseIndentation:
|
145
|
+
Enabled: True
|
146
|
+
|
147
|
+
Style/CharacterLiteral:
|
148
|
+
Enabled: True
|
149
|
+
|
150
|
+
Style/ClassAndModuleCamelCase:
|
151
|
+
Enabled: True
|
152
|
+
|
153
|
+
Style/ClassAndModuleChildren:
|
154
|
+
Enabled: False
|
155
|
+
|
156
|
+
Style/ClassCheck:
|
157
|
+
Enabled: True
|
158
|
+
|
159
|
+
# Class length is not necessarily an indicator of code quality
|
160
|
+
Metrics/ClassLength:
|
161
|
+
Enabled: False
|
162
|
+
|
163
|
+
Style/ClassMethods:
|
164
|
+
Enabled: True
|
165
|
+
|
166
|
+
Style/ClassVars:
|
167
|
+
Enabled: True
|
168
|
+
|
169
|
+
Style/WhenThen:
|
170
|
+
Enabled: True
|
171
|
+
|
172
|
+
Style/WordArray:
|
173
|
+
Enabled: True
|
174
|
+
|
175
|
+
Style/UnneededPercentQ:
|
176
|
+
Enabled: True
|
177
|
+
|
178
|
+
Style/Tab:
|
179
|
+
Enabled: True
|
180
|
+
|
181
|
+
Style/SpaceBeforeSemicolon:
|
182
|
+
Enabled: True
|
183
|
+
|
184
|
+
Style/TrailingBlankLines:
|
185
|
+
Enabled: True
|
186
|
+
|
187
|
+
Style/SpaceInsideBlockBraces:
|
188
|
+
Enabled: True
|
189
|
+
|
190
|
+
Style/SpaceInsideBrackets:
|
191
|
+
Enabled: True
|
192
|
+
|
193
|
+
Style/SpaceInsideHashLiteralBraces:
|
194
|
+
Enabled: True
|
195
|
+
|
196
|
+
Style/SpaceInsideParens:
|
197
|
+
Enabled: True
|
198
|
+
|
199
|
+
Style/LeadingCommentSpace:
|
200
|
+
Enabled: True
|
201
|
+
|
202
|
+
Style/SpaceBeforeFirstArg:
|
203
|
+
Enabled: True
|
204
|
+
|
205
|
+
Style/SpaceAfterColon:
|
206
|
+
Enabled: True
|
207
|
+
|
208
|
+
Style/SpaceAfterComma:
|
209
|
+
Enabled: True
|
210
|
+
|
211
|
+
Style/SpaceAfterMethodName:
|
212
|
+
Enabled: True
|
213
|
+
|
214
|
+
Style/SpaceAfterNot:
|
215
|
+
Enabled: True
|
216
|
+
|
217
|
+
Style/SpaceAfterSemicolon:
|
218
|
+
Enabled: True
|
219
|
+
|
220
|
+
Style/SpaceAroundEqualsInParameterDefault:
|
221
|
+
Enabled: True
|
222
|
+
|
223
|
+
Style/SpaceAroundOperators:
|
224
|
+
Enabled: True
|
225
|
+
|
226
|
+
Style/SpaceBeforeBlockBraces:
|
227
|
+
Enabled: True
|
228
|
+
|
229
|
+
Style/SpaceBeforeComma:
|
230
|
+
Enabled: True
|
231
|
+
|
232
|
+
Style/CollectionMethods:
|
233
|
+
Enabled: True
|
234
|
+
|
235
|
+
Style/CommentIndentation:
|
236
|
+
Enabled: True
|
237
|
+
|
238
|
+
Style/ColonMethodCall:
|
239
|
+
Enabled: True
|
240
|
+
|
241
|
+
Style/CommentAnnotation:
|
242
|
+
Enabled: True
|
243
|
+
|
244
|
+
# 'Complexity' is very relative
|
245
|
+
Metrics/CyclomaticComplexity:
|
246
|
+
Enabled: False
|
247
|
+
|
248
|
+
Style/ConstantName:
|
249
|
+
Enabled: True
|
250
|
+
|
251
|
+
Style/Documentation:
|
252
|
+
Enabled: False
|
253
|
+
|
254
|
+
Style/DefWithParentheses:
|
255
|
+
Enabled: True
|
256
|
+
|
257
|
+
Style/PreferredHashMethods:
|
258
|
+
Enabled: True
|
259
|
+
|
260
|
+
Style/DotPosition:
|
261
|
+
EnforcedStyle: trailing
|
262
|
+
|
263
|
+
Style/DoubleNegation:
|
264
|
+
Enabled: True
|
265
|
+
|
266
|
+
Style/EachWithObject:
|
267
|
+
Enabled: True
|
268
|
+
|
269
|
+
Style/EmptyLineBetweenDefs:
|
270
|
+
Enabled: True
|
271
|
+
|
272
|
+
Style/IndentArray:
|
273
|
+
Enabled: True
|
274
|
+
|
275
|
+
Style/IndentHash:
|
276
|
+
Enabled: True
|
277
|
+
|
278
|
+
Style/IndentationConsistency:
|
279
|
+
Enabled: True
|
280
|
+
|
281
|
+
Style/IndentationWidth:
|
282
|
+
Enabled: True
|
283
|
+
|
284
|
+
Style/EmptyLines:
|
285
|
+
Enabled: True
|
286
|
+
|
287
|
+
Style/EmptyLinesAroundAccessModifier:
|
288
|
+
Enabled: True
|
289
|
+
|
290
|
+
Style/EmptyLiteral:
|
291
|
+
Enabled: True
|
292
|
+
|
293
|
+
# Configuration parameters: AllowURI, URISchemes.
|
294
|
+
Metrics/LineLength:
|
295
|
+
Enabled: False
|
296
|
+
|
297
|
+
Style/MethodCallParentheses:
|
298
|
+
Enabled: True
|
299
|
+
|
300
|
+
Style/MethodDefParentheses:
|
301
|
+
Enabled: True
|
302
|
+
|
303
|
+
Style/LineEndConcatenation:
|
304
|
+
Enabled: True
|
305
|
+
|
306
|
+
Style/TrailingWhitespace:
|
307
|
+
Enabled: True
|
308
|
+
|
309
|
+
Style/StringLiterals:
|
310
|
+
Enabled: True
|
311
|
+
|
312
|
+
Style/TrailingCommaInArguments:
|
313
|
+
Enabled: True
|
314
|
+
|
315
|
+
Style/TrailingCommaInLiteral:
|
316
|
+
Enabled: True
|
317
|
+
|
318
|
+
Style/GlobalVars:
|
319
|
+
Enabled: True
|
320
|
+
|
321
|
+
Style/GuardClause:
|
322
|
+
Enabled: True
|
323
|
+
|
324
|
+
Style/IfUnlessModifier:
|
325
|
+
Enabled: True
|
326
|
+
|
327
|
+
Style/MultilineIfThen:
|
328
|
+
Enabled: True
|
329
|
+
|
330
|
+
Style/NegatedIf:
|
331
|
+
Enabled: True
|
332
|
+
|
333
|
+
Style/NegatedWhile:
|
334
|
+
Enabled: True
|
335
|
+
|
336
|
+
Style/Next:
|
337
|
+
Enabled: True
|
338
|
+
|
339
|
+
Style/SingleLineBlockParams:
|
340
|
+
Enabled: True
|
341
|
+
|
342
|
+
Style/SingleLineMethods:
|
343
|
+
Enabled: True
|
344
|
+
|
345
|
+
Style/SpecialGlobalVars:
|
346
|
+
Enabled: True
|
347
|
+
|
348
|
+
Style/TrivialAccessors:
|
349
|
+
Enabled: True
|
350
|
+
|
351
|
+
Style/UnlessElse:
|
352
|
+
Enabled: True
|
353
|
+
|
354
|
+
Style/VariableInterpolation:
|
355
|
+
Enabled: True
|
356
|
+
|
357
|
+
Style/VariableName:
|
358
|
+
Enabled: True
|
359
|
+
|
360
|
+
Style/WhileUntilDo:
|
361
|
+
Enabled: True
|
362
|
+
|
363
|
+
Style/EvenOdd:
|
364
|
+
Enabled: True
|
365
|
+
|
366
|
+
Style/FileName:
|
367
|
+
Enabled: True
|
368
|
+
|
369
|
+
Style/For:
|
370
|
+
Enabled: True
|
371
|
+
|
372
|
+
Style/Lambda:
|
373
|
+
Enabled: True
|
374
|
+
|
375
|
+
Style/MethodName:
|
376
|
+
Enabled: True
|
377
|
+
|
378
|
+
Style/MultilineTernaryOperator:
|
379
|
+
Enabled: True
|
380
|
+
|
381
|
+
Style/NestedTernaryOperator:
|
382
|
+
Enabled: True
|
383
|
+
|
384
|
+
Style/NilComparison:
|
385
|
+
Enabled: True
|
386
|
+
|
387
|
+
Style/FormatString:
|
388
|
+
Enabled: True
|
389
|
+
|
390
|
+
Style/MultilineBlockChain:
|
391
|
+
Enabled: True
|
392
|
+
|
393
|
+
Style/Semicolon:
|
394
|
+
Enabled: True
|
395
|
+
|
396
|
+
Style/SignalException:
|
397
|
+
Enabled: True
|
398
|
+
|
399
|
+
Style/NonNilCheck:
|
400
|
+
Enabled: True
|
401
|
+
|
402
|
+
Style/Not:
|
403
|
+
Enabled: True
|
404
|
+
|
405
|
+
Style/NumericLiterals:
|
406
|
+
Enabled: True
|
407
|
+
|
408
|
+
Style/OneLineConditional:
|
409
|
+
Enabled: True
|
410
|
+
|
411
|
+
Style/OpMethod:
|
412
|
+
Enabled: True
|
413
|
+
|
414
|
+
Style/ParenthesesAroundCondition:
|
415
|
+
Enabled: True
|
416
|
+
|
417
|
+
Style/PercentLiteralDelimiters:
|
418
|
+
Enabled: True
|
419
|
+
|
420
|
+
Style/PerlBackrefs:
|
421
|
+
Enabled: True
|
422
|
+
|
423
|
+
Style/PredicateName:
|
424
|
+
Enabled: True
|
425
|
+
|
426
|
+
Style/RedundantException:
|
427
|
+
Enabled: True
|
428
|
+
|
429
|
+
Style/SelfAssignment:
|
430
|
+
Enabled: True
|
431
|
+
|
432
|
+
Style/Proc:
|
433
|
+
Enabled: True
|
434
|
+
|
435
|
+
Style/RaiseArgs:
|
436
|
+
Enabled: True
|
437
|
+
|
438
|
+
Style/RedundantBegin:
|
439
|
+
Enabled: True
|
440
|
+
|
441
|
+
Style/RescueModifier:
|
442
|
+
Enabled: True
|
443
|
+
|
444
|
+
# based on https://github.com/voxpupuli/modulesync_config/issues/168
|
445
|
+
Style/RegexpLiteral:
|
446
|
+
EnforcedStyle: percent_r
|
447
|
+
Enabled: True
|
448
|
+
|
449
|
+
Lint/UnderscorePrefixedVariableName:
|
450
|
+
Enabled: True
|
451
|
+
|
452
|
+
Metrics/ParameterLists:
|
453
|
+
Enabled: False
|
454
|
+
|
455
|
+
Lint/RequireParentheses:
|
456
|
+
Enabled: True
|
457
|
+
|
458
|
+
Style/SpaceBeforeFirstArg:
|
459
|
+
Enabled: True
|
460
|
+
|
461
|
+
Style/ModuleFunction:
|
462
|
+
Enabled: True
|
463
|
+
|
464
|
+
Lint/Debugger:
|
465
|
+
Enabled: True
|
466
|
+
|
467
|
+
Style/IfWithSemicolon:
|
468
|
+
Enabled: True
|
469
|
+
|
470
|
+
Style/Encoding:
|
471
|
+
Enabled: True
|
472
|
+
|
473
|
+
Style/BlockDelimiters:
|
474
|
+
Enabled: True
|
475
|
+
|
476
|
+
Style/MultilineBlockLayout:
|
477
|
+
Enabled: True
|
478
|
+
|
479
|
+
# 'Complexity' is very relative
|
480
|
+
Metrics/AbcSize:
|
481
|
+
Enabled: False
|
482
|
+
|
483
|
+
# 'Complexity' is very relative
|
484
|
+
Metrics/PerceivedComplexity:
|
485
|
+
Enabled: False
|
486
|
+
|
487
|
+
Lint/UselessAssignment:
|
488
|
+
Enabled: True
|
489
|
+
|
490
|
+
Style/ClosingParenthesisIndentation:
|
491
|
+
Enabled: False
|
492
|
+
|
493
|
+
# RSpec
|
494
|
+
|
495
|
+
# We don't use rspec in this way
|
496
|
+
RSpec/DescribeClass:
|
497
|
+
Enabled: False
|
498
|
+
|
499
|
+
# Example length is not necessarily an indicator of code quality
|
500
|
+
RSpec/ExampleLength:
|
501
|
+
Enabled: False
|
502
|
+
|
503
|
+
RSpec/NamedSubject:
|
504
|
+
Enabled: False
|
data/.travis.yml
CHANGED
@@ -1,11 +1,22 @@
|
|
1
|
+
sudo: false
|
1
2
|
language: ruby
|
2
|
-
|
3
|
+
cache: bundler
|
4
|
+
before_install:
|
3
5
|
# https://github.com/bundler/bundler/issues/3558
|
4
6
|
gem update bundler
|
5
|
-
script: bundle exec rake spec
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
- 2.1
|
7
|
+
script: bundle exec rake spec
|
8
|
+
matrix:
|
9
|
+
fast_finish: true
|
10
|
+
include:
|
11
|
+
- rvm: 2.3.1
|
12
|
+
env: PUPPET_GEM_VERSION='~> 4.0'
|
13
|
+
- rvm: 2.1
|
14
|
+
env: PUPPET_GEM_VERSION='~> 4.0'
|
15
|
+
- rvm: 2.1
|
16
|
+
env: PUPPET_GEM_VERSION='~> 3.0'
|
17
|
+
- rvm: 2.0
|
18
|
+
env: PUPPET_GEM_VERSION='~> 3.0'
|
19
|
+
- rvm: 1.9.3
|
20
|
+
env: PUPPET_GEM_VERSION='~> 3.0'
|
10
21
|
notifications:
|
11
22
|
email: false
|
data/CHANGELOG.md
CHANGED
@@ -2,11 +2,53 @@
|
|
2
2
|
All notable changes to this project will be documented in this file.
|
3
3
|
This project adheres to [Semantic Versioning](http://semver.org/).
|
4
4
|
|
5
|
-
## [1.
|
5
|
+
## [1.2.1]
|
6
|
+
### Summary:
|
7
|
+
|
8
|
+
The previous release was taken down, as some optional gem dependencies slipped through into the gemspec, breaking builds using ruby 2.2 and earlier. This release updates the gem build process, so this should not happen again.
|
9
|
+
|
10
|
+
## [1.2.0] - 2016-08-23
|
11
|
+
### Summary:
|
12
|
+
|
13
|
+
Add a bunch of new features, and fix a bunch of annoying bugs: parallel test execution, default to strict variable checking on Puppet 4, code coverage, and rubocop tasks.
|
14
|
+
|
15
|
+
Thanks to all community contributors: Alexander Fisher, Alex Harvey, Chris Tessmer, David Moreno García, Dmitry Ilyin, Dominic Cleal, Federico Voges, Garrett Honeycutt, Leo Arnold, Matthew Haughton, Mickaël Canévet, and Rob Nelson.
|
16
|
+
|
17
|
+
### Added:
|
18
|
+
|
19
|
+
New tasks:
|
20
|
+
* Add code coverage for Ruby >= 1.9 using SimpleCov.
|
21
|
+
* Add a rubocop rake task.
|
22
|
+
* Use beaker:ssh to log into your running beaker machines.
|
23
|
+
|
24
|
+
Spec parallelization
|
25
|
+
* Add `parallel_spec` task to run specs in parallel.
|
26
|
+
* Use CI_NODE_TOTAL and CI_NODE_INDEX to split tests across nodes.
|
27
|
+
|
28
|
+
Fixtures improvements:
|
29
|
+
* Automatically symlink the module directory, if no symlink fixtures are specified.
|
30
|
+
* Add the `subdir` key to repository fixtures to only use a part of that repository.
|
31
|
+
* Set `FIXTURES_YML` environment variable to load fixtures from somewhere else than `.fixtures.yml`.
|
32
|
+
|
33
|
+
## Changed:
|
34
|
+
* Updated default excludes and rspec patterns.
|
35
|
+
* Updated default disabled lint checks to work with puppet-lint 2.0.0.
|
36
|
+
* Testing on Puppet 4 will now default to strict variable checking. Set STRICT_VARIABLES=no to disable.
|
37
|
+
* `PuppetInternals.scope` is now deprecated. Use the new `scope` property from rspec-puppet.
|
38
|
+
* beaker_nodes is now called beaker:sets.
|
39
|
+
|
40
|
+
### Fixed:
|
41
|
+
* Ignore symlinks inside .git when running check:symlinks rake task.
|
42
|
+
* Allow multiple invocations of spec_prep to run in parallel.
|
43
|
+
* Address a race condition when cloning multiple git fixtures.
|
44
|
+
* Restrict gem dependencies to work with ruby 1.9.
|
45
|
+
* Update verify_contents() to work with duplicates in the arguments.
|
46
|
+
|
47
|
+
## [1.1.1] - 2016-03-02
|
6
48
|
### Fixed:
|
7
|
-
Readded and properly deprecated the `
|
49
|
+
Readded and properly deprecated the `metadata` rake task. Use the `metadata_lint` task from metadata-json-lint directly instead.
|
8
50
|
|
9
|
-
## [1.1.0] -
|
51
|
+
## [1.1.0] - 2016-02-25
|
10
52
|
### Summary:
|
11
53
|
This release adds the ability to clone fixtures from git in parallel, speeding
|
12
54
|
up the spec\_prep rake task.
|
@@ -234,6 +276,8 @@ compatible yet.
|
|
234
276
|
* Initial release
|
235
277
|
|
236
278
|
[unreleased]: https://github.com/puppetlabs/puppetlabs_spec_helper/compare/1.1.1...master
|
279
|
+
[1.2.1]: https://github.com/puppetlabs/puppetlabs_spec_helper/compare/1.2.0...1.2.1
|
280
|
+
[1.2.0]: https://github.com/puppetlabs/puppetlabs_spec_helper/compare/1.1.1...1.2.0
|
237
281
|
[1.1.1]: https://github.com/puppetlabs/puppetlabs_spec_helper/compare/1.1.0...1.1.1
|
238
282
|
[1.1.0]: https://github.com/puppetlabs/puppetlabs_spec_helper/compare/1.0.1...1.1.0
|
239
283
|
[1.0.1]: https://github.com/puppetlabs/puppetlabs_spec_helper/compare/1.0.0...1.0.1
|
data/CONTRIBUTING.md
CHANGED
@@ -1,55 +1,14 @@
|
|
1
1
|
# DEVELOPMENT NOTES
|
2
2
|
|
3
3
|
## Building Gemspec
|
4
|
-
The Rakefile includes all the info that the gemspec file will contain. You have to update
|
5
|
-
the Rakefile instead of the gemspec.
|
6
|
-
To regenerate the gemspec just run `rake gemspec` and a new gemspec will be created
|
7
|
-
with everything required.
|
8
|
-
|
9
|
-
Running `rake build` will build out the gemspec according to the Rakefile parameters.
|
10
|
-
|
11
|
-
```ruby
|
12
|
-
Jeweler::Tasks.new do |gem|
|
13
|
-
# gem is a Gem::Specification... see http://docs.rubygems.org/read/chapter/20 for more options
|
14
|
-
gem.name = "puppetlabs_spec_helper"
|
15
|
-
gem.version = "#{PuppetlabsSpecHelper::Version::STRING}"
|
16
|
-
gem.homepage = "http://github.com/puppetlabs/puppetlabs_spec_helper"
|
17
|
-
gem.license = "Apache-2.0"
|
18
|
-
gem.summary = %Q{Standard tasks and configuration for module spec tests}
|
19
|
-
gem.description = %Q{Contains rake tasks and a standard spec_helper for running spec tests on puppet modules}
|
20
|
-
gem.email = ["modules-dept@puppetlabs.com"]
|
21
|
-
gem.authors = ["Puppet Labs"]
|
22
|
-
# dependencies defined in Gemfile
|
23
|
-
end
|
24
|
-
|
25
|
-
```
|
26
|
-
|
27
|
-
## Version file
|
28
|
-
As part of the `rake gemspec` task, the gemspec will reference the version that is
|
29
|
-
defined in the `lib/puppetlabs_spec_helper/version.rb` file.
|
30
4
|
|
5
|
+
To keep the gem accessible to people running older rubies, the gemspec may only contain dependencies on gems that are available to all supported rubies. Features that need gems compatible only to some versions of ruby need to be coded in a way that is optional, and specify their gem dependencies in the Gemfile, conditional on the ruby version. Add a note to the README about those.
|
31
6
|
|
32
7
|
## Releasing
|
33
|
-
To release the gem
|
8
|
+
To release the gem run the following things.
|
34
9
|
|
35
10
|
### 1. Update the version
|
36
|
-
update the version file
|
37
|
-
|
38
|
-
```ruby
|
39
|
-
module PuppetlabsSpecHelper
|
40
|
-
module Version
|
41
|
-
STRING = '1.0.1'
|
42
|
-
end
|
43
|
-
end
|
44
|
-
```
|
45
|
-
|
46
|
-
### 2. Generate and push the release to git
|
47
|
-
rake gemspec:release
|
48
|
-
|
49
|
-
### 3. Tag and release to git
|
50
|
-
Since the default behavior of jewler is to use tags like `v1.0.1` we cannot use
|
51
|
-
the `git:release` task and will need to use `git:pl_release` which creates a tag
|
52
|
-
without the `v` and pushes to master.
|
11
|
+
update the version file: `lib/puppetlabs_spec_helper/version.rb`
|
53
12
|
|
54
|
-
###
|
55
|
-
rake release
|
13
|
+
### 2. Release the gem
|
14
|
+
rake release[remote]
|
data/Gemfile
CHANGED
@@ -1,16 +1,22 @@
|
|
1
1
|
source 'https://rubygems.org'
|
2
2
|
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
gem 'puppet-syntax'
|
7
|
-
gem 'mocha'
|
3
|
+
# Specify the global dependencies in puppetlabs_spec_helper.gemspec
|
4
|
+
# Note that only ruby 1.9 compatible dependencies may go there, everything else needs to be documented and pulled in manually, and optionally by everyone who wants to use the extended features.
|
5
|
+
gemspec
|
8
6
|
|
9
7
|
group :development do
|
10
|
-
gem '
|
11
|
-
|
12
|
-
|
13
|
-
|
8
|
+
gem "puppet", ENV['PUPPET_GEM_VERSION'] || ENV['PUPPET_VERSION'] || '~> 4.0'
|
9
|
+
if RUBY_VERSION =~ /^1\./
|
10
|
+
gem 'rubocop', '0.41.2'
|
11
|
+
else
|
12
|
+
gem 'rubocop'
|
13
|
+
gem 'rubocop-rspec', '~> 1.6' if RUBY_VERSION >= '2.3.0'
|
14
|
+
end
|
14
15
|
end
|
15
16
|
|
17
|
+
# json_pure 2.0.2 added a requirement on ruby >= 2. We pin to json_pure 2.0.1
|
18
|
+
# if using ruby 1.x
|
19
|
+
gem 'json_pure', '<=2.0.1', :require => false if RUBY_VERSION =~ /^1\./
|
20
|
+
gem 'rack', '~> 1'
|
21
|
+
|
16
22
|
# vim:filetype=ruby
|