core: get rid of more references to scope, old terminology
This commit is contained in:
parent
26366d0673
commit
f2f58655e8
|
@ -76,7 +76,7 @@ module Vagrant
|
||||||
opts = {}
|
opts = {}
|
||||||
opts = data.pop if data.last.kind_of?(Hash)
|
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
|
# Prepare the data by replacing characters that aren't outputted
|
||||||
data.each_index do |i|
|
data.each_index do |i|
|
||||||
|
@ -225,7 +225,7 @@ module Vagrant
|
||||||
def machine(type, *data)
|
def machine(type, *data)
|
||||||
opts = {}
|
opts = {}
|
||||||
opts = data.pop if data.last.is_a?(Hash)
|
opts = data.pop if data.last.is_a?(Hash)
|
||||||
opts[:scope] = @prefix
|
opts[:target] = @prefix
|
||||||
data << opts
|
data << opts
|
||||||
@ui.machine(type, *data)
|
@ui.machine(type, *data)
|
||||||
end
|
end
|
||||||
|
|
|
@ -166,13 +166,13 @@ describe Vagrant::UI::Prefixed do
|
||||||
end
|
end
|
||||||
|
|
||||||
describe "#machine" do
|
describe "#machine" do
|
||||||
it "sets the scope option" do
|
it "sets the target option" do
|
||||||
ui.should_receive(:machine).with(:foo, scope: prefix)
|
ui.should_receive(:machine).with(:foo, target: prefix)
|
||||||
subject.machine(:foo)
|
subject.machine(:foo)
|
||||||
end
|
end
|
||||||
|
|
||||||
it "preserves existing options" do
|
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)
|
subject.machine(:foo, :bar, foo: :bar)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue