vagrant-openstack-provider 0.5.1 → 0.5.2
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 06f76da66e9d69d7b3750c87355a2b0cd494d82e
|
4
|
+
data.tar.gz: 94b6f3cfae8334fecf64e9fc69d1e8e2da651659
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: afa0415d10ee018a52bb356c3bb3a387ae9035c84d44696d16f38f87e854cc72a85ed73c002203775f83b5fb7ed5814fc25406ac854e98dbb66f7062509b218f
|
7
|
+
data.tar.gz: 33d2530168597883a587064f92571ca8a8291efe617b1f38d4ba154eafa90d7b16b7ff08b4d27adf820755b155f2718a8699a7db417d5ad3f70df6d3a3b15aaa
|
data/CHANGELOG.md
CHANGED
@@ -13,7 +13,7 @@ module VagrantPlugins
|
|
13
13
|
return network_detail['addr'] if network_detail['OS-EXT-IPS:type'] == 'floating'
|
14
14
|
end
|
15
15
|
end
|
16
|
-
return details['addresses'].first[1][0]['addr'] if details['addresses'].size
|
16
|
+
return details['addresses'].first[1][0]['addr'] if details['addresses'].size >= 1 && details['addresses'].first[1].size >= 1
|
17
17
|
fail Errors::UnableToResolveIP
|
18
18
|
end
|
19
19
|
end
|
@@ -87,6 +87,32 @@ describe VagrantPlugins::Openstack::Utils do
|
|
87
87
|
}
|
88
88
|
}
|
89
89
|
end
|
90
|
+
expect(@action.get_ip_address(env)).to eq('13.13.13.13')
|
91
|
+
end
|
92
|
+
end
|
93
|
+
|
94
|
+
context 'with networks but no ips' do
|
95
|
+
it 'fails' do
|
96
|
+
config.stub(:floating_ip) { nil }
|
97
|
+
nova.stub(:get_server_details).with(env, '1234id') do
|
98
|
+
{
|
99
|
+
'addresses' => {
|
100
|
+
'toto' => []
|
101
|
+
}
|
102
|
+
}
|
103
|
+
end
|
104
|
+
expect { @action.get_ip_address(env) }.to raise_error(Errors::UnableToResolveIP)
|
105
|
+
end
|
106
|
+
end
|
107
|
+
|
108
|
+
context 'with no networks ' do
|
109
|
+
it 'fails' do
|
110
|
+
config.stub(:floating_ip) { nil }
|
111
|
+
nova.stub(:get_server_details).with(env, '1234id') do
|
112
|
+
{
|
113
|
+
'addresses' => {}
|
114
|
+
}
|
115
|
+
end
|
90
116
|
expect { @action.get_ip_address(env) }.to raise_error(Errors::UnableToResolveIP)
|
91
117
|
end
|
92
118
|
end
|