mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
Merge pull request #1999 from sbergmann/master
Fix #server so that it returns the right server instead of all servers
This commit is contained in:
commit
2b3b024c72
2 changed files with 2 additions and 2 deletions
|
@ -71,7 +71,7 @@ module Fog
|
||||||
|
|
||||||
def server
|
def server
|
||||||
requires :server_id
|
requires :server_id
|
||||||
service.servers('instance-id' => server_id)
|
service.servers.get(server_id)
|
||||||
end
|
end
|
||||||
|
|
||||||
def server=(new_server)
|
def server=(new_server)
|
||||||
|
|
|
@ -14,7 +14,7 @@ Shindo.tests("Fog::Compute[:aws] | volume", ['aws']) do
|
||||||
@instance.wait_for { state == 'in-use' }
|
@instance.wait_for { state == 'in-use' }
|
||||||
|
|
||||||
tests('#server').succeeds do
|
tests('#server').succeeds do
|
||||||
@instance.server
|
@instance.server.id == @server.id
|
||||||
end
|
end
|
||||||
|
|
||||||
tests('#server = nil').succeeds do
|
tests('#server = nil').succeeds do
|
||||||
|
|
Loading…
Reference in a new issue