1
0
Fork 0
mirror of https://github.com/fog/fog.git synced 2022-11-09 13:51:43 -05:00
fog--fog/tests/compute/requests/voxel/image_tests.rb
2011-02-24 16:40:12 -08:00

46 lines
1.1 KiB
Ruby

Shindo.tests('Voxel::Compute | image requests', ['voxel']) do
@images_format = [{
'id' => Integer,
'summary' => String
}]
@image_format = {
'description' => String,
'id' => Integer,
'filesystem' => {
'size' => Integer,
'type' => String,
'units' => String,
},
'operating_system' => {
'admin_username' => String,
'architecture' => Integer,
'family' => String,
'product_family' => String,
'product_version' => String,
'version' => String
},
'summary' => String
}
tests('success') do
tests('#images_list').formats(@images_format) do
pending if Fog.mocking?
Voxel[:compute].images_list
end
tests('#images_list(1)').formats([@image_format]) do
pending if Fog.mocking?
Voxel[:compute].images_list(1)
end
end
tests('failure') do
tests('#images_list(0)').raises(Fog::Voxel::Compute::Error) do
pending if Fog.mocking?
Voxel[:compute].images_list(0)
end
end
end