ansible_spec 0.2.11 → 0.2.12

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 3b872942bcb5a26a23247723d84188a992f97a60
4
- data.tar.gz: 21638a57a71751bddee6bffbe849f9f8fbe39ee3
3
+ metadata.gz: c42f90775318c0e351f6a915ccc24623b5fc618e
4
+ data.tar.gz: 8005d3431744adef64fa79ce870e064342588bf3
5
5
  SHA512:
6
- metadata.gz: 47625ffe1bf1c4e0f81c22908c2b904215b7681a719f95559fab61e522524d28be309cec5bd77a21a3a4f28fa872e1036df637ae417ccb4e36947f9b7022285c
7
- data.tar.gz: 05078e9080269b7f7dc9d793dde918e4a1af5c1839b3905fcdde229c4c74f707e2980ff650dcfebb8baf787214231d5e1d6818166ac93a8bec22a0934344a2b9
6
+ metadata.gz: d8e35e9e9c0c9ccf21cc7cfc25f7abcef6e69f9209d93355f2e9c5c72777c2083ff5fe2617b57838cc48930ea14ffbee8052ea77c72a89c0bdfee8e694d6a576
7
+ data.tar.gz: 72e6986ac52f2df01fdd5487dbf578bf4186b7ec3539fb6c5f4c8ba1ca4ecacb73dd77f400fa8cfab4eaec05f7f3cf8fdb1ab3dc42dbb70cb2069b16c14c0592
@@ -1,3 +1,6 @@
1
+ - v0.2.12
2
+ - Merge [Support deep merge for variable](https://github.com/volanja/ansible_spec/pull/72) by [okamototk](https://github.com/okamototk)
3
+
1
4
  - v0.2.11
2
5
  - Merge [Support Windows](https://github.com/volanja/ansible_spec/pull/68) by [takuyakawabuchi](https://github.com/takuyakawabuchi)
3
6
 
data/README.md CHANGED
@@ -47,14 +47,16 @@ customize the playbook and inventory using an `.ansiblespec` file.
47
47
  -
48
48
  playbook: site.yml
49
49
  inventory: hosts
50
+ hash_behaviour: merge
50
51
  ```
51
52
 
52
53
  ## [Optional] Environment variables
53
54
 
54
55
  You can use environment variables with the `rake` command. They are listed below.
55
56
 
56
- - `PLAYBOOK` -- playbook name (e.g. `site.yml`)
57
- - `INVENTORY` -- inventory file name (e.g. `hosts`)
57
+ - `PLAYBOOK` -- playbook name (e.g. `site.yml`)
58
+ - `INVENTORY` -- inventory file name (e.g. `hosts`)
59
+ - `HASH_BEHAVIOUR` -- hash behaviour when duplicate hash variables (e.g. `merge`)
58
60
 
59
61
  Environment variables take precedence over the `.ansiblespec` file.
60
62
 
@@ -66,8 +68,13 @@ or
66
68
  $ PLAYBOOK=site.yml rake serverspec:Ansible-Sample-TDD
67
69
  or
68
70
  $ INVENTORY=hosts rake serverspec:Ansible-Sample-TDD
71
+ or
72
+ $ HASH_BEHAVIOUR=merge rake serverspec:Ansible-Sample-TDD
69
73
  ```
70
74
 
75
+ HASH_BEHAVIOUR is same as Ansible's hash behaviour parameter. By default, 'replace'.
76
+ See http://docs.ansible.com/ansible/intro_configuration.html#hash-behaviour.
77
+
71
78
  ## Inventory
72
79
 
73
80
  Inventory files can:
@@ -1,7 +1,9 @@
1
+ # -*- coding: utf-8 -*-
1
2
  require 'hostlist_expression'
2
3
  require 'oj'
3
4
  require 'open3'
4
5
  require 'yaml'
6
+ require 'ansible_spec/vendor/hash'
5
7
 
6
8
  module AnsibleSpec
7
9
  # param: inventory file of Ansible
@@ -177,7 +179,6 @@ module AnsibleSpec
177
179
  else
178
180
  inventoryfile = 'hosts'
179
181
  end
180
-
181
182
  if File.exist?(playbook) == false
182
183
  puts 'Error: ' + playbook + ' is not Found. create site.yml or ./.ansiblespec See https://github.com/volanja/ansible_spec'
183
184
  exit 1
@@ -270,22 +271,53 @@ module AnsibleSpec
270
271
  end
271
272
  end
272
273
 
274
+ # param: none
275
+ # return: hash_behaviour
276
+ def self.get_hash_behaviour()
277
+ f = '.ansiblespec'
278
+ y = nil
279
+ if File.exist?(f)
280
+ y = YAML.load_file(f)
281
+ end
282
+ hash_behaviour = 'replace'
283
+ if ENV["HASH_BEHAVIOUR"]
284
+ hash_behaviour = ENV["HASH_BEHAVIOUR"]
285
+ elsif y.is_a?(Array) && y[0]['hash_behaviour']
286
+ hash_behaviour = y[0]['hash_behaviour']
287
+ end
288
+ if !['replace','merge'].include?(hash_behaviour)
289
+ puts "Error: hash_behaviour '" + hash_behaviour + "' should be 'replace' or 'merge' See https://github.com/volanja/ansible_spec"
290
+ exit 1
291
+ end
292
+ return hash_behaviour
293
+ end
294
+
273
295
  # param: hash
274
296
  # param: variable file
275
- def self.load_vars_file(vars, path)
297
+ # param: flag to extention
298
+ # true: .yml extension is optional
299
+ # false: must have .yml extention
300
+ def self.load_vars_file(vars, path, check_no_ext = false)
276
301
  vars_file = path
302
+ if check_no_ext && !File.exist?(vars_file)
303
+ vars_file = path+".yml"
304
+ end
277
305
  if File.exist?(vars_file)
278
306
  yaml = YAML.load_file(vars_file)
279
- if yaml.kind_of?(Hash)
280
- vars.merge!(yaml)
281
- end
282
- else
283
- vars_file = path+".yml"
284
- if File.exist?(vars_file)
285
- yaml = YAML.load_file(vars_file)
286
- if yaml.kind_of?(Hash)
287
- vars.merge!(yaml)
288
- end
307
+ vars = merge_variables(vars, yaml)
308
+ end
309
+ return vars
310
+ end
311
+
312
+ # param: target hash
313
+ # param: be merged hash
314
+ def self.merge_variables(vars, hash)
315
+ hash_behaviour = get_hash_behaviour()
316
+ if hash.kind_of?(Hash)
317
+ if hash_behaviour=="merge"
318
+ vars.deep_merge!(hash)
319
+ else
320
+ vars.merge!(hash)
289
321
  end
290
322
  end
291
323
  return vars
@@ -319,46 +351,31 @@ module AnsibleSpec
319
351
 
320
352
  # roles default
321
353
  p[group_idx]['roles'].each do |role|
322
- vars_file = "roles/#{role}/defaults/main.yml"
323
- if File.exist?(vars_file)
324
- yaml = YAML.load_file(vars_file)
325
- if yaml.kind_of?(Hash)
326
- vars.merge!(yaml)
327
- end
328
- end
354
+ vars = load_vars_file(vars ,"roles/#{role}/defaults/main.yml")
329
355
  end
330
356
 
331
357
  # all group
332
- vars = load_vars_file(vars ,'group_vars/all')
358
+ vars = load_vars_file(vars ,'group_vars/all', true)
333
359
 
334
360
  # each group vars
335
361
  if p[group_idx].has_key?('group')
336
- vars = load_vars_file(vars ,"group_vars/#{p[group_idx]['group']}")
362
+ vars = load_vars_file(vars ,"group_vars/#{p[group_idx]['group']}", true)
337
363
  end
338
364
 
339
365
  # each host vars
340
- vars = load_vars_file(vars ,"host_vars/#{host}")
366
+ vars = load_vars_file(vars ,"host_vars/#{host}", true)
341
367
 
342
368
  # site vars
343
369
  if p[group_idx].has_key?('vars')
344
- if p[group_idx]['vars'].kind_of?(Hash)
345
- vars.merge!(p[group_idx]['vars'])
346
- end
370
+ vars = merge_variables(vars, p[group_idx]['vars'])
347
371
  end
348
372
 
349
373
  # roles vars
350
374
  p[group_idx]['roles'].each do |role|
351
- vars_file = "roles/#{role}/vars/main.yml"
352
- if File.exist?(vars_file)
353
- yaml = YAML.load_file(vars_file)
354
- if yaml.kind_of?(Hash)
355
- vars.merge!(yaml)
356
- end
357
- end
375
+ vars = load_vars_file(vars ,"roles/#{role}/vars/main.yml")
358
376
  end
359
377
 
360
378
  return vars
361
379
 
362
380
  end
363
-
364
381
  end
@@ -0,0 +1,20 @@
1
+ Copyright (c) 2005-2014 David Heinemeier Hansson
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining
4
+ a copy of this software and associated documentation files (the
5
+ "Software"), to deal in the Software without restriction, including
6
+ without limitation the rights to use, copy, modify, merge, publish,
7
+ distribute, sublicense, and/or sell copies of the Software, and to
8
+ permit persons to whom the Software is furnished to do so, subject to
9
+ the following conditions:
10
+
11
+ The above copyright notice and this permission notice shall be
12
+ included in all copies or substantial portions of the Software.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@@ -0,0 +1,38 @@
1
+ class Hash
2
+ # Returns a new hash with +self+ and +other_hash+ merged recursively.
3
+ #
4
+ # h1 = { a: true, b: { c: [1, 2, 3] } }
5
+ # h2 = { a: false, b: { x: [3, 4, 5] } }
6
+ #
7
+ # h1.deep_merge(h2) #=> { a: false, b: { c: [1, 2, 3], x: [3, 4, 5] } }
8
+ #
9
+ # Like with Hash#merge in the standard library, a block can be provided
10
+ # to merge values:
11
+ #
12
+ # h1 = { a: 100, b: 200, c: { c1: 100 } }
13
+ # h2 = { b: 250, c: { c1: 200 } }
14
+ # h1.deep_merge(h2) { |key, this_val, other_val| this_val + other_val }
15
+ # # => { a: 100, b: 450, c: { c1: 300 } }
16
+ def deep_merge(other_hash, &block)
17
+ dup.deep_merge!(other_hash, &block)
18
+ end
19
+
20
+ # Same as +deep_merge+, but modifies +self+.
21
+ def deep_merge!(other_hash, &block)
22
+ other_hash.each_pair do |current_key, other_value|
23
+ this_value = self[current_key]
24
+
25
+ self[current_key] = if this_value.is_a?(Hash) && other_value.is_a?(Hash)
26
+ this_value.deep_merge(other_value, &block)
27
+ else
28
+ if block_given? && key?(current_key)
29
+ block.call(current_key, this_value, other_value)
30
+ else
31
+ other_value
32
+ end
33
+ end
34
+ end
35
+
36
+ self
37
+ end
38
+ end
@@ -1,3 +1,3 @@
1
1
  module AnsibleSpec
2
- VERSION = "0.2.11"
2
+ VERSION = "0.2.12"
3
3
  end
@@ -0,0 +1,4 @@
1
+ ---
2
+ -
3
+ playbook: site.yml
4
+ inventory: hosts
@@ -0,0 +1,5 @@
1
+ [merge]
2
+ 192.168.1.1
3
+
4
+
5
+
@@ -0,0 +1,4 @@
1
+ ---
2
+ merge_var:
3
+ keep: "role"
4
+ override: "role"
@@ -0,0 +1,9 @@
1
+ - name: merge
2
+ hosts: merge
3
+ connection: local
4
+ vars:
5
+ merge_var:
6
+ override: "site"
7
+ add: "site"
8
+ roles:
9
+ - test
@@ -0,0 +1,5 @@
1
+ ---
2
+ -
3
+ playbook: site.yml
4
+ inventory: hosts
5
+ hash_behaviour: merge
@@ -0,0 +1,5 @@
1
+ [merge]
2
+ 192.168.1.1
3
+
4
+
5
+
@@ -0,0 +1,4 @@
1
+ ---
2
+ merge_var:
3
+ keep: "role"
4
+ override: "role"
@@ -0,0 +1,9 @@
1
+ - name: merge
2
+ hosts: merge
3
+ connection: local
4
+ vars:
5
+ merge_var:
6
+ override: "site"
7
+ add: "site"
8
+ roles:
9
+ - test
@@ -0,0 +1,5 @@
1
+ ---
2
+ -
3
+ playbook: site.yml
4
+ inventory: hosts
5
+ hash_behaviour: merge
@@ -0,0 +1,5 @@
1
+ [merge]
2
+ 192.168.1.1
3
+
4
+
5
+
@@ -0,0 +1,4 @@
1
+ ---
2
+ merge_var:
3
+ keep: "role"
4
+ override: "role"
@@ -0,0 +1,9 @@
1
+ - name: merge
2
+ hosts: merge
3
+ connection: local
4
+ vars:
5
+ merge_var:
6
+ override: "site"
7
+ add: "site"
8
+ roles:
9
+ - test
@@ -0,0 +1,5 @@
1
+ ---
2
+ -
3
+ playbook: site.yml
4
+ inventory: hosts
5
+ hash_behaviour: merge
@@ -0,0 +1,5 @@
1
+ ---
2
+ -
3
+ playbook: site.yml
4
+ inventory: hosts
5
+ hash_behaviour: merge
@@ -0,0 +1,2 @@
1
+ ---
2
+ role_var: "without .yml extension"
@@ -224,6 +224,189 @@ describe "get_variablesの実行" do
224
224
  Dir.chdir(@current_dir)
225
225
  end
226
226
  end
227
+
228
+ context 'Correct operation : deep_merge' do
229
+ before do
230
+ @current_dir = Dir.pwd()
231
+ Dir.chdir('spec/case/get_variable/deep_merge')
232
+ @res = AnsibleSpec.get_variables('192.168.1.1', 0)
233
+ end
234
+
235
+ it 'res is hash' do
236
+ expect(@res.instance_of?(Hash)).to be_truthy
237
+ end
238
+
239
+ it 'exist 1 pair in Hash' do
240
+ expect(@res.length).to eq 1
241
+ end
242
+
243
+ it 'exist each pair' do
244
+ expect(@res).to include({'merge_var' => {
245
+ 'keep'=>'role',
246
+ 'override'=>'site',
247
+ 'add'=>'site'
248
+ }},
249
+ )
250
+ end
251
+
252
+ after do
253
+ Dir.chdir(@current_dir)
254
+ end
255
+ end
256
+
257
+ end
258
+
259
+ describe "get_hash_behaviourの実行" do
260
+ context 'Correct operation : should get replace' do
261
+ before do
262
+ @current_dir = Dir.pwd()
263
+ Dir.chdir('spec/case/get_hash_behaviour/basic')
264
+ end
265
+
266
+ it 'should get replace' do
267
+ res = AnsibleSpec.get_hash_behaviour()
268
+ expect(res).to eq 'replace'
269
+ end
270
+
271
+ after do
272
+ Dir.chdir(@current_dir)
273
+ end
274
+ end
275
+
276
+ context 'Correct operation : merge in ENV["HASH_BEHAVIOUR"]' do
277
+ before do
278
+ ENV["HASH_BEHAVIOUR"] = 'merge'
279
+ @current_dir = Dir.pwd()
280
+ Dir.chdir('spec/case/get_hash_behaviour/basic')
281
+ end
282
+
283
+ it 'should get merge' do
284
+ res = AnsibleSpec.get_hash_behaviour()
285
+ expect(res).to eq 'merge'
286
+ end
287
+
288
+ after do
289
+ ENV.delete('HASH_BEHAVIOUR')
290
+ Dir.chdir(@current_dir)
291
+ end
292
+ end
293
+
294
+ context 'Correct operation : mistake word in ENV["HASH_BEHAVIOUR"]' do
295
+ before do
296
+ ENV["HASH_BEHAVIOUR"] = 'mistake_word'
297
+ @current_dir = Dir.pwd()
298
+ Dir.chdir('spec/case/get_hash_behaviour/basic')
299
+ end
300
+
301
+ it 'exitする' do
302
+ expect{ AnsibleSpec.get_hash_behaviour }.to raise_error(SystemExit)
303
+ end
304
+
305
+ after do
306
+ ENV.delete('HASH_BEHAVIOUR')
307
+ Dir.chdir(@current_dir)
308
+ end
309
+ end
310
+
311
+ context 'Correct operation : with .ansiblespec' do
312
+ before do
313
+ @current_dir = Dir.pwd()
314
+ Dir.chdir('spec/case/get_hash_behaviour/with_ansiblespec')
315
+ end
316
+
317
+ it 'should get merge' do
318
+ res = AnsibleSpec.get_hash_behaviour()
319
+ expect(res).to eq 'merge'
320
+ end
321
+
322
+ after do
323
+ ENV.delete('HASH_BEHAVIOUR')
324
+ Dir.chdir(@current_dir)
325
+ end
326
+ end
327
+
328
+ context 'Correct operation : overwrite ENV["HASH_BEHAVIOUR"]' do
329
+ before do
330
+ ENV["HASH_BEHAVIOUR"] = 'replace'
331
+ @current_dir = Dir.pwd()
332
+ Dir.chdir('spec/case/get_hash_behaviour/with_ansiblespec')
333
+ end
334
+
335
+ it 'should get merge' do
336
+ res = AnsibleSpec.get_hash_behaviour()
337
+ expect(res).to eq 'replace'
338
+ end
339
+
340
+ after do
341
+ ENV.delete('HASH_BEHAVIOUR')
342
+ Dir.chdir(@current_dir)
343
+ end
344
+ end
345
+ end
346
+
347
+ describe 'merge_variablesの実行' do
348
+ context 'Correct operation : deep_merge (merge)' do
349
+ before do
350
+ @current_dir = Dir.pwd()
351
+ Dir.chdir('spec/case/get_variable/deep_merge')
352
+ h1 = {'merge_var' => {'keep'=>'h1','override'=>'h1','add'=>'h1'}}
353
+ h2 = {'merge_var' => {'override'=>'h2','add'=>'h2'}}
354
+ @res = AnsibleSpec.merge_variables(h1, h2)
355
+ end
356
+
357
+ it 'res is hash' do
358
+ expect(@res.instance_of?(Hash)).to be_truthy
359
+ end
360
+
361
+ it 'exist 1 pair in Hash' do
362
+ expect(@res.length).to eq 1
363
+ end
364
+
365
+ it 'should h1 + h2' do
366
+ expect(@res).to include({'merge_var' => {
367
+ 'keep'=>'h1',
368
+ 'override'=>'h2',
369
+ 'add'=>'h2'
370
+ }},
371
+ )
372
+ end
373
+
374
+ after do
375
+ Dir.chdir(@current_dir)
376
+ end
377
+ end
378
+
379
+ context 'Correct operation : deep_merge (replace)' do
380
+ before do
381
+ ENV["HASH_BEHAVIOUR"] = 'replace'
382
+ @current_dir = Dir.pwd()
383
+ Dir.chdir('spec/case/get_variable/deep_merge')
384
+ h1 = {'merge_var' => {'keep'=>'h1','override'=>'h1','add'=>'h1'}}
385
+ h2 = {'merge_var' => {'override'=>'h2','add'=>'h2'}}
386
+ @res = AnsibleSpec.merge_variables(h1, h2)
387
+ end
388
+
389
+ it 'res is hash' do
390
+ expect(@res.instance_of?(Hash)).to be_truthy
391
+ end
392
+
393
+ it 'exist 1 pair in Hash' do
394
+ expect(@res.length).to eq 1
395
+ end
396
+
397
+ it 'should replace from h1 to h2' do
398
+ expect(@res).to include({'merge_var' => {
399
+ 'override'=>'h2',
400
+ 'add'=>'h2'
401
+ }},
402
+ )
403
+ end
404
+
405
+ after do
406
+ ENV.delete('HASH_BEHAVIOUR')
407
+ Dir.chdir(@current_dir)
408
+ end
409
+ end
227
410
  end
228
411
 
229
412
  describe "load_vars_fileの実行" do
@@ -254,4 +437,32 @@ describe "load_vars_fileの実行" do
254
437
  Dir.chdir(@current_dir)
255
438
  end
256
439
  end
440
+
441
+ context 'Correct operation : deep merge' do
442
+ # https://github.com/volanja/ansible_spec/pull/66
443
+ # group_vars/xxx priority is higher than group_vars/xxx.yml.
444
+ before do
445
+ @current_dir = Dir.pwd()
446
+ Dir.chdir('spec/case/load_vars_file/group_all_deep_merge/')
447
+ vars = Hash.new
448
+ file = 'group_vars/all'
449
+ @res = AnsibleSpec.load_vars_file(vars, file, true)
450
+ end
451
+
452
+ it 'res is hash' do
453
+ expect(@res.instance_of?(Hash)).to be_truthy
454
+ end
455
+
456
+ it 'exist 1 pair in Hash' do
457
+ expect(@res.length).to eq 1
458
+ end
459
+
460
+ it 'exist each pair' do
461
+ expect(@res).to include({'role_var' => 'without .yml extension'})
462
+ end
463
+
464
+ after do
465
+ Dir.chdir(@current_dir)
466
+ end
467
+ end
257
468
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ansible_spec
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.11
4
+ version: 0.2.12
5
5
  platform: ruby
6
6
  authors:
7
7
  - volanja
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-04-03 00:00:00.000000000 Z
11
+ date: 2016-04-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -143,10 +143,24 @@ files:
143
143
  - bin/ansiblespec-init
144
144
  - lib/ansible_spec.rb
145
145
  - lib/ansible_spec/load_ansible.rb
146
+ - lib/ansible_spec/vendor/MIT-LICENSE
147
+ - lib/ansible_spec/vendor/hash.rb
146
148
  - lib/ansible_spec/version.rb
147
149
  - lib/src/.ansiblespec
148
150
  - lib/src/Rakefile
149
151
  - lib/src/spec/spec_helper.rb
152
+ - spec/case/get_hash_behaviour/basic/.ansiblespec
153
+ - spec/case/get_hash_behaviour/basic/hosts
154
+ - spec/case/get_hash_behaviour/basic/roles/test/defaults/main.yml
155
+ - spec/case/get_hash_behaviour/basic/site.yml
156
+ - spec/case/get_hash_behaviour/with_ansiblespec/.ansiblespec
157
+ - spec/case/get_hash_behaviour/with_ansiblespec/hosts
158
+ - spec/case/get_hash_behaviour/with_ansiblespec/roles/test/defaults/main.yml
159
+ - spec/case/get_hash_behaviour/with_ansiblespec/site.yml
160
+ - spec/case/get_variable/deep_merge/.ansiblespec
161
+ - spec/case/get_variable/deep_merge/hosts
162
+ - spec/case/get_variable/deep_merge/roles/test/defaults/main.yml
163
+ - spec/case/get_variable/deep_merge/site.yml
150
164
  - spec/case/get_variable/group_all/group_vars/all.yml
151
165
  - spec/case/get_variable/group_all/hosts
152
166
  - spec/case/get_variable/group_all/roles/test/defaults/main.yml
@@ -177,8 +191,11 @@ files:
177
191
  - spec/case/get_variable/roles_default/hosts
178
192
  - spec/case/get_variable/roles_default/roles/test/defaults/main.yml
179
193
  - spec/case/get_variable/roles_default/site.yml
194
+ - spec/case/load_vars_file/group_all/.ansiblespec
180
195
  - spec/case/load_vars_file/group_all/group_vars/all
181
196
  - spec/case/load_vars_file/group_all/group_vars/all.yml
197
+ - spec/case/load_vars_file/group_all_deep_merge/.ansiblespec
198
+ - spec/case/load_vars_file/group_all_deep_merge/group_vars/all.yml
182
199
  - spec/commands_spec.rb
183
200
  - spec/dependency_spec.rb
184
201
  - spec/dynamic_inventory_spec.rb
@@ -214,6 +231,18 @@ specification_version: 4
214
231
  summary: Ansible Config Parser for Serverspec. Run test Multi Role and Multi Host
215
232
  by Ansible Configuration
216
233
  test_files:
234
+ - spec/case/get_hash_behaviour/basic/.ansiblespec
235
+ - spec/case/get_hash_behaviour/basic/hosts
236
+ - spec/case/get_hash_behaviour/basic/roles/test/defaults/main.yml
237
+ - spec/case/get_hash_behaviour/basic/site.yml
238
+ - spec/case/get_hash_behaviour/with_ansiblespec/.ansiblespec
239
+ - spec/case/get_hash_behaviour/with_ansiblespec/hosts
240
+ - spec/case/get_hash_behaviour/with_ansiblespec/roles/test/defaults/main.yml
241
+ - spec/case/get_hash_behaviour/with_ansiblespec/site.yml
242
+ - spec/case/get_variable/deep_merge/.ansiblespec
243
+ - spec/case/get_variable/deep_merge/hosts
244
+ - spec/case/get_variable/deep_merge/roles/test/defaults/main.yml
245
+ - spec/case/get_variable/deep_merge/site.yml
217
246
  - spec/case/get_variable/group_all/group_vars/all.yml
218
247
  - spec/case/get_variable/group_all/hosts
219
248
  - spec/case/get_variable/group_all/roles/test/defaults/main.yml
@@ -244,8 +273,11 @@ test_files:
244
273
  - spec/case/get_variable/roles_default/hosts
245
274
  - spec/case/get_variable/roles_default/roles/test/defaults/main.yml
246
275
  - spec/case/get_variable/roles_default/site.yml
276
+ - spec/case/load_vars_file/group_all/.ansiblespec
247
277
  - spec/case/load_vars_file/group_all/group_vars/all
248
278
  - spec/case/load_vars_file/group_all/group_vars/all.yml
279
+ - spec/case/load_vars_file/group_all_deep_merge/.ansiblespec
280
+ - spec/case/load_vars_file/group_all_deep_merge/group_vars/all.yml
249
281
  - spec/commands_spec.rb
250
282
  - spec/dependency_spec.rb
251
283
  - spec/dynamic_inventory_spec.rb