test: fix test for default provider

This commit is contained in:
Mitchell Hashimoto 2014-10-23 16:41:24 -07:00
parent 4bbe43df0d
commit 13dc1832b6
1 changed files with 3 additions and 2 deletions

View File

@ -798,13 +798,14 @@ VF
end
end
it "is VirtualBox if nothing else is usable" do
it "raise an error if nothing else is usable" do
plugin_providers[:foo] = [provider_usable_class(false), { priority: 5 }]
plugin_providers[:bar] = [provider_usable_class(false), { priority: 5 }]
plugin_providers[:baz] = [provider_usable_class(false), { priority: 5 }]
with_temp_env("VAGRANT_DEFAULT_PROVIDER" => nil) do
expect(subject.default_provider).to eq(:virtualbox)
expect { subject.default_provider }.to raise_error(
Vagrant::Errors::NoDefaultProvider)
end
end