2010-09-09 20:50:38 -04:00
|
|
|
require File.dirname(__FILE__) + '/../../../spec_helper'
|
|
|
|
require File.dirname(__FILE__) + '/../../../shared_examples/server_examples'
|
2010-05-24 14:03:52 -04:00
|
|
|
|
2010-09-09 20:50:38 -04:00
|
|
|
describe 'Fog::Bluebox::Compute::Server' do
|
2010-05-24 14:03:52 -04:00
|
|
|
|
|
|
|
it_should_behave_like "Server"
|
|
|
|
|
|
|
|
subject {
|
2010-06-04 01:02:17 -04:00
|
|
|
@flavor_id = '94fd37a7-2606-47f7-84d5-9000deda52ae' # Block 1GB Virtual Server
|
|
|
|
@image_id = 'a00baa8f-b5d0-4815-8238-b471c4c4bf72' # Ubuntu 9.10 64bit
|
2010-06-04 01:20:31 -04:00
|
|
|
@server = @servers.new(:flavor_id => @flavor_id, :image_id => @image_id, :password => "chunkybacon")
|
2010-05-24 14:03:52 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
before(:each) do
|
2010-09-09 20:50:38 -04:00
|
|
|
@servers = Bluebox[:compute].servers
|
2010-05-24 14:03:52 -04:00
|
|
|
end
|
|
|
|
|
|
|
|
after(:each) do
|
|
|
|
if @server && !@server.new_record?
|
|
|
|
@server.wait_for { ready? }
|
|
|
|
@server.destroy.should be_true
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
end
|