Sha256: 21965c921a13e4bf4f84d9eab50a4c4f7dff8634a2d638a2480ba86882db3add

Contents?: true

Size: 811 Bytes

Versions: 119

Compression:

Stored size: 811 Bytes

Contents

shared_examples_for "Server" do

  describe "#reboot" do

    it "should succeed" do
      subject.save
      subject.wait_for { ready? }
      subject.reboot.should be_true
    end

  end

  describe "#reload" do

    it "should reset attributes to remote state" do
      subject.save
      subject.wait_for { ready? }
      @reloaded = subject.reload
      subject.attributes.should == @reloaded.attributes
    end

  end

  describe "#save" do

    it "should return true when it succeeds" do
      subject.save.should be_true
    end

    it "should not exist remotely before save" do
      @servers.get(subject.id).should be_nil
    end

    it "should exist remotely after save" do
      subject.save
      subject.wait_for { ready? }
      @servers.get(subject.id).should_not be_nil
    end

  end

end

Version data entries

119 entries across 119 versions & 2 rubygems

Version Path
fog-0.3.17 spec/shared_examples/server_examples.rb
fog-0.3.16 spec/shared_examples/server_examples.rb
fog-0.3.15 spec/shared_examples/server_examples.rb
fog-0.3.14 spec/shared_examples/server_examples.rb
fog-0.3.13 spec/shared_examples/server_examples.rb
fog-0.3.12 spec/shared_examples/server_examples.rb
fog-0.3.11 spec/shared_examples/server_examples.rb
fog-0.3.10 spec/shared_examples/server_examples.rb
fog-0.3.9 spec/shared_examples/server_examples.rb
fog-0.3.8 spec/shared_examples/server_examples.rb
fog-0.3.7 spec/shared_examples/server_examples.rb
fog-0.3.6 spec/shared_examples/server_examples.rb
fog-0.3.5 spec/shared_examples/server_examples.rb
fog-0.3.4 spec/shared_examples/server_examples.rb
fog-0.3.3 spec/shared_examples/server_examples.rb
fog-0.3.2 spec/shared_examples/server_examples.rb
fog-0.3.1 spec/shared_examples/server_examples.rb
fog-0.3.0 spec/shared_examples/server_examples.rb
fog-0.2.30 spec/shared_examples/server_examples.rb
fog-0.2.28 spec/shared_examples/server_examples.rb