mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
Modified Fog::Compute::RackspaceV2 destroy image test from test setup
This commit is contained in:
parent
b2e542d7a3
commit
2f2d602866
1 changed files with 10 additions and 10 deletions
|
@ -12,17 +12,17 @@ Shindo.tests('Fog::Compute::RackspaceV2 | image', ['rackspace']) do
|
|||
|
||||
|
||||
tests("success") do
|
||||
tests("destroy").succeeds do
|
||||
begin
|
||||
server = service.servers.create(options)
|
||||
server.wait_for { ready? }
|
||||
image_id = server.create_image("fog_image_#{test_time}")
|
||||
image = service.images.get(image_id)
|
||||
begin
|
||||
server = service.servers.create(options)
|
||||
server.wait_for { ready? }
|
||||
image_id = server.create_image("fog_image_#{test_time}")
|
||||
image = service.images.get(image_id)
|
||||
|
||||
tests("destroy").succeeds do
|
||||
image.destroy
|
||||
ensure
|
||||
server.destroy if server
|
||||
end
|
||||
ensure
|
||||
server.destroy if server
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue