Better test coverage on with_target_vms. Added pending tests to work on.
This commit is contained in:
parent
07157b47ae
commit
24c3c9a7ae
|
@ -157,6 +157,26 @@ describe Vagrant::Plugin::V2::Command do
|
||||||
instance.with_target_vms(name, :provider => provider) { |vm| vms << vm }
|
instance.with_target_vms(name, :provider => provider) { |vm| vms << vm }
|
||||||
vms.should == [vmware_vm]
|
vms.should == [vmware_vm]
|
||||||
end
|
end
|
||||||
|
|
||||||
|
it "should use the default provider if none is given and none are active" do
|
||||||
|
name = :foo
|
||||||
|
machine = double("machine")
|
||||||
|
|
||||||
|
environment.stub(:machine).with(name, default_provider).and_return(machine)
|
||||||
|
machine.stub(:name => name, :provider => default_provider)
|
||||||
|
|
||||||
|
results = []
|
||||||
|
instance.with_target_vms(name) { |m| results << m }
|
||||||
|
results.should == [machine]
|
||||||
|
end
|
||||||
|
|
||||||
|
it "should use the primary machine with the active provider" do
|
||||||
|
pending
|
||||||
|
end
|
||||||
|
|
||||||
|
it "should use the primary machine with the default provider" do
|
||||||
|
pending
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
describe "splitting the main and subcommand args" do
|
describe "splitting the main and subcommand args" do
|
||||||
|
|
Loading…
Reference in New Issue