ansible_spec 0.2.3 → 0.2.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: d5c5766164945b71de78de3396370ec97e4e15b4
4
- data.tar.gz: 9d492a8f97f9ca39f75c7ff5976ed50f25165ba6
3
+ metadata.gz: c4883e779389ae7096bdce09a7e572a699f86f1c
4
+ data.tar.gz: 144e14d67f8d46b48fb0f80b29bb79ea32510d27
5
5
  SHA512:
6
- metadata.gz: 10a085f6d9032b544180a6f63e1d016e085397b84d750787afe99aa7ae7aae769af2213120b676a0199e56dc693075104c399b6c051e8e1d61daeae343912a62
7
- data.tar.gz: 612a7cc90293e939587e5c5f5f962c3409a9bc012304eff5196dd754d5a14c71bb41a54c870a2cbdd2b855f5d56aea7af0d3e8575af37bfbd293b6070b26fbed
6
+ metadata.gz: 8f91185a22486befc9314296258734fad2848e2ee533ffe4800eb3147eeca70524e4bbbcc513f02429a16bbb9436e8545311f4289759a418f9af79fdba84dae1
7
+ data.tar.gz: ec415b24ec8dd9c9f97e0c3c89a88382c223b3f0754c224ef92b692bf329fc643710435111a2559ba1c77c094ba91cb17d48fb0945a7d5b158c8b62f537a075e
data/CHANGELOG.md CHANGED
@@ -1,3 +1,6 @@
1
+ # v0.2.4
2
+ - Fix [#50 do not fail on no hosts matched](https://github.com/volanja/ansible_spec/pull/50) by [phiche](https://github.com/phiche)
3
+
1
4
  # v0.2.3
2
5
  - Fix [#47 NoMethodError: undefined method 'each' for nil:NilClass if inventory has "roles"=>[]](https://github.com/volanja/ansible_spec/issues/47) by [phiche](https://github.com/phiche)
3
6
 
@@ -239,7 +239,7 @@ module AnsibleSpec
239
239
  elsif hosts.has_key?("#{var["hosts"]}")
240
240
  var["hosts"] = hosts["#{var["hosts"]}"]
241
241
  else
242
- fail "no hosts matched"
242
+ puts "no hosts matched for #{var["hosts"]}"
243
243
  end
244
244
  end
245
245
  return properties
@@ -1,3 +1,3 @@
1
1
  module AnsibleSpec
2
- VERSION = "0.2.3"
2
+ VERSION = "0.2.4"
3
3
  end
@@ -1259,50 +1259,4 @@ EOF
1259
1259
  end
1260
1260
  end
1261
1261
 
1262
- context '異常系 (hosts is not match)' do
1263
- require 'yaml'
1264
- tmp_ansiblespec = '.ansiblespec'
1265
- tmp_playbook = 'site.yml'
1266
- tmp_hosts = 'hosts'
1267
-
1268
- before do
1269
-
1270
- content = <<'EOF'
1271
- ---
1272
- -
1273
- playbook: site.yml
1274
- inventory: hosts
1275
- EOF
1276
-
1277
- content_p = <<'EOF'
1278
- - name: Ansible-Sample-TDD
1279
- hosts: match
1280
- user: root
1281
- roles:
1282
- - nginx
1283
- - mariadb
1284
- EOF
1285
-
1286
- content_h = <<'EOF'
1287
- [server]
1288
- 192.168.0.103
1289
- 192.168.0.104
1290
- EOF
1291
-
1292
- create_file(tmp_ansiblespec,content)
1293
- create_file(tmp_playbook,content_p)
1294
- create_file(tmp_hosts,content_h)
1295
- end
1296
-
1297
- it 'exitする' do
1298
- expect{ AnsibleSpec.get_properties }.to raise_error("no hosts matched")
1299
- end
1300
-
1301
- after do
1302
- File.delete(tmp_ansiblespec)
1303
- File.delete(tmp_playbook)
1304
- File.delete(tmp_hosts)
1305
- end
1306
- end
1307
-
1308
1262
  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.3
4
+ version: 0.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - volanja
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-10-06 00:00:00.000000000 Z
11
+ date: 2015-11-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler