Fixed a bug with forwarded ports action
This commit is contained in:
parent
b115fc0ea0
commit
c176a04cfa
|
@ -10,10 +10,10 @@ module Vagrant
|
||||||
port.name = name
|
port.name = name
|
||||||
port.hostport = options[:hostport]
|
port.hostport = options[:hostport]
|
||||||
port.guestport = options[:guestport]
|
port.guestport = options[:guestport]
|
||||||
@vm.forwarded_ports << port
|
@vm.vm.forwarded_ports << port
|
||||||
end
|
end
|
||||||
|
|
||||||
@vm.save(true)
|
@vm.vm.save(true)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -18,8 +18,8 @@ class ForwardPortsActionTest < Test::Unit::TestCase
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
@mock_vm.expects(:forwarded_ports).returns(forwarded_ports)
|
@vm.expects(:forwarded_ports).returns(forwarded_ports)
|
||||||
@mock_vm.expects(:save).with(true).once
|
@vm.expects(:save).with(true).once
|
||||||
@action.execute!
|
@action.execute!
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue