Update destroy to use new API for VB4
This commit is contained in:
parent
083c820a1b
commit
e4488c415e
|
@ -1,6 +1,8 @@
|
||||||
## 0.6.10 (unreleased)
|
## 0.7.0 (unreleased)
|
||||||
|
|
||||||
|
|
||||||
|
- VirtualBox 4.0 support. Support for VirtualBox 3.2 is _dropped_, since
|
||||||
|
the API is so different. Stay with the 0.6.x series if you have VirtualBox
|
||||||
|
3.2.x.
|
||||||
|
|
||||||
## 0.6.9 (December 21, 2010)
|
## 0.6.9 (December 21, 2010)
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@ module Vagrant
|
||||||
|
|
||||||
def call(env)
|
def call(env)
|
||||||
env.ui.info I18n.t("vagrant.actions.vm.destroy.destroying")
|
env.ui.info I18n.t("vagrant.actions.vm.destroy.destroying")
|
||||||
env["vm"].vm.destroy(:destroy_medium => :delete)
|
env["vm"].vm.destroy
|
||||||
env["vm"].vm = nil
|
env["vm"].vm = nil
|
||||||
|
|
||||||
@app.call(env)
|
@app.call(env)
|
||||||
|
|
|
@ -16,7 +16,7 @@ class DestroyVMActionTest < Test::Unit::TestCase
|
||||||
|
|
||||||
context "destroying the VM" do
|
context "destroying the VM" do
|
||||||
should "destroy VM and attached images" do
|
should "destroy VM and attached images" do
|
||||||
@internal_vm.expects(:destroy).with(:destroy_medium => :delete).once
|
@internal_vm.expects(:destroy).once
|
||||||
@env["vm"].expects(:vm=).with(nil).once
|
@env["vm"].expects(:vm=).with(nil).once
|
||||||
@app.expects(:call).with(@env).once
|
@app.expects(:call).with(@env).once
|
||||||
@instance.call(@env)
|
@instance.call(@env)
|
||||||
|
|
Loading…
Reference in New Issue