mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
Adding test coverage of deleting agent tokens
This commit is contained in:
parent
5f7338d77f
commit
b2c80e988e
1 changed files with 6 additions and 0 deletions
|
@ -16,6 +16,9 @@ Shindo.tests('Fog::Rackspace::Monitoring | agent_tests', ['rackspace','rackspace
|
||||||
tests('#get agent token').formats(LIST_HEADERS_FORMAT) do
|
tests('#get agent token').formats(LIST_HEADERS_FORMAT) do
|
||||||
account.get_agent_token(agent_token).data[:headers]
|
account.get_agent_token(agent_token).data[:headers]
|
||||||
end
|
end
|
||||||
|
tests('#delete agent token').formats(DELETE_HEADERS_FORMAT) do
|
||||||
|
account.delete_agent_token(agent_token).data[:headers]
|
||||||
|
end
|
||||||
end
|
end
|
||||||
tests('failure') do
|
tests('failure') do
|
||||||
tests('#fail to create agent token(-1)').raises(TypeError) do
|
tests('#fail to create agent token(-1)').raises(TypeError) do
|
||||||
|
@ -24,5 +27,8 @@ Shindo.tests('Fog::Rackspace::Monitoring | agent_tests', ['rackspace','rackspace
|
||||||
tests('#fail to get agent token(-1)').raises(TypeError) do
|
tests('#fail to get agent token(-1)').raises(TypeError) do
|
||||||
account.create_agent_token(-1)
|
account.create_agent_token(-1)
|
||||||
end
|
end
|
||||||
|
tests('#fail to delete agent token(-1)').raises(Fog::Rackspace::Monitoring::NotFound) do
|
||||||
|
account.delete_agent_token(-1)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Add table
Reference in a new issue