1
0
Fork 0
mirror of https://github.com/fog/fog.git synced 2022-11-09 13:51:43 -05:00

[cloudstack] prevent mock test failure when cloudstack credentials are not defined

This commit is contained in:
geemus 2012-05-28 12:59:37 -05:00
parent 8992b32d40
commit b081342b44

View file

@ -26,12 +26,12 @@ def compute_providers
},
:server_attributes => {}.tap do |hash|
[:zone_id, :network_ids, :image_id, :flavor_id].each do |k|
hash[k]= Fog.credentials[:cloudstack][k]
hash[k]= Fog.credentials[:cloudstack] && Fog.credentials[:cloudstack][k]
end
end,
:volume_attributes => {:name => "somevolume"}.tap do |hash|
[:zone_id, :disk_offering_id].each do |k|
hash[k]= Fog.credentials[:cloudstack][k]
hash[k]= Fog.credentials[:cloudstack] && Fog.credentials[:cloudstack][k]
end
end,
:mocked => true