lib/fog/openstack/requests/image/update_image_members.rb in fog-1.19.0 vs lib/fog/openstack/requests/image/update_image_members.rb in fog-1.20.0
- old
+ new
@@ -10,20 +10,20 @@
# ]
data = { 'memberships' => members }
request(
:body => Fog::JSON.encode(data),
- :expects => [200, 202],
+ :expects => [204],
:method => 'PUT',
:path => "images/#{image_id}/members"
)
end
end # class Real
class Mock
def update_image_members(image_id, members)
response = Excon::Response.new
- response.status = [200, 202][rand(1)]
+ response.status = 204
response.body = {
'members' => [
{ 'member_id'=>'ff528b20431645ebb5fa4b0a71ca002f', 'can_share' => false },
{ 'member_id'=>'ff528b20431645ebb5fa4b0a71ca002f', 'can_share' => true }
]