core: get rid of more references to scope, old terminology

This commit is contained in:
Mitchell Hashimoto 2014-01-21 12:06:04 -08:00
parent 26366d0673
commit f2f58655e8
2 changed files with 5 additions and 5 deletions

View File

@ -76,7 +76,7 @@ module Vagrant
opts = {}
opts = data.pop if data.last.kind_of?(Hash)
target = opts[:scope] || ""
target = opts[:target] || ""
# Prepare the data by replacing characters that aren't outputted
data.each_index do |i|
@ -225,7 +225,7 @@ module Vagrant
def machine(type, *data)
opts = {}
opts = data.pop if data.last.is_a?(Hash)
opts[:scope] = @prefix
opts[:target] = @prefix
data << opts
@ui.machine(type, *data)
end

View File

@ -166,13 +166,13 @@ describe Vagrant::UI::Prefixed do
end
describe "#machine" do
it "sets the scope option" do
ui.should_receive(:machine).with(:foo, scope: prefix)
it "sets the target option" do
ui.should_receive(:machine).with(:foo, target: prefix)
subject.machine(:foo)
end
it "preserves existing options" do
ui.should_receive(:machine).with(:foo, :bar, foo: :bar, scope: prefix)
ui.should_receive(:machine).with(:foo, :bar, foo: :bar, target: prefix)
subject.machine(:foo, :bar, foo: :bar)
end
end