Sha256: d0bb67ffa3784354cdca2f8f1e7165c660e023f59681e849c1e7489b78b820e3
Contents?: true
Size: 897 Bytes
Versions: 31
Compression:
Stored size: 897 Bytes
Contents
require File.dirname(__FILE__) + '/../../../spec_helper' describe 'Rackspace::Servers.delete_image' do describe 'success' do before(:each) do # flavor 1 = 256, image 3 = gentoo 2008.0 @server_id = Rackspace[:servers].create_server(1, 3, 'name').body['server']['id'] @image_id = Rackspace[:servers].create_image(@server_id).body['image']['id'] end it "should return proper attributes" do eventually(128) do Rackspace[:servers].delete_server(@server_id) end end it "should return proper attributes" do eventually(128) do Rackspace[:servers].delete_image(@image_id) end end end describe 'failure' do it "should raise a BadRequest error if the image does not exist" do lambda do Rackspace[:servers].delete_image(0) end.should raise_error(Excon::Errors::BadRequest) end end end
Version data entries
31 entries across 31 versions & 1 rubygems