1
0
Fork 0
mirror of https://github.com/fog/fog.git synced 2022-11-09 13:51:43 -05:00
fog--fog/tests/digitalocean/requests/compute/list_images_tests.rb

25 lines
577 B
Ruby
Raw Normal View History

Shindo.tests('Fog::Compute[:digitalocean] | list_images request', ['digitalocean', 'compute']) do
# {"id"=>1601, "name"=>"CentOS 5.8 x64", "distribution"=>"CentOS"}
@image_format = {
'id' => Integer,
'name' => String,
'distribution' => String
}
tests('success') do
tests('#list_images') do
images = Fog::Compute[:digitalocean].list_images.body
test 'returns a Hash' do
images.is_a? Hash
end
tests('image').formats(@image_format, false) do
images['images'].first
end
end
end
end