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

[openstack|image] Fixed update image and list public images mocks

This commit is contained in:
Alvin Garcia 2012-08-17 15:54:39 +08:00 committed by Nelvin Driz
parent d50fe64007
commit 8d06517538
3 changed files with 3 additions and 3 deletions

View file

@ -19,7 +19,7 @@ module Fog
end # class Real
class Mock
def list_public_images_detailed
def list_public_images_detailed(attribute=nil, query=nil)
response = Excon::Response.new
response.status = [200, 204][rand(1)]
response.body = {"images"=>[{

View file

@ -56,7 +56,7 @@ module Fog
"min_ram"=>0,
"owner"=>"728ecc7c10614a1faa6fbabd1a68a4a0",
"properties"=>{}
}
}.merge(Hash[attributes.map { |key, val| [key.to_s, val] }])
}
response

View file

@ -56,7 +56,7 @@ Shindo.tests('Fog::Image[:openstack] | image requests', ['openstack']) do
end
tests('#list_public_images_detailed').formats({'images' => [@image_format]}) do
Fog::Image[:openstack].list_public_images.body
Fog::Image[:openstack].list_public_images_detailed.body
end
tests('#create_image').formats({'image' => @image_format}) do