1
0
Fork 0
mirror of https://github.com/fog/fog.git synced 2022-11-09 13:51:43 -05:00
fog--fog/lib/fog/openstack/requests/identity/delete_user_role.rb
Dan Prince 65a90fd655 OpenStack: get identity tests passing in real mode
Updates to the OpenStack identity tests to they pass in both real
and mock modes.

Also, fixes an issue in the delete_user_role request where it
was expecting 200 instead of 204 (which seems to match the
spec and implementation).
2013-01-28 13:07:22 -05:00

26 lines
545 B
Ruby

module Fog
module Identity
class OpenStack
class Real
def delete_user_role(tenant_id, user_id, role_id)
request(
:expects => 204,
:method => 'DELETE',
:path => "/tenants/#{tenant_id}/users/#{user_id}/roles/OS-KSADM/#{role_id}"
)
end
end
class Mock
def delete_user_role(tenant_id, user_id, role_id)
response = Excon::Response.new
response.status = 204
response
end
end
end
end
end