Config#execute! returns the newly loaded configuration
This commit is contained in:
parent
a7652244d5
commit
e84b17e215
|
@ -29,6 +29,7 @@ module Vagrant
|
||||||
def execute!
|
def execute!
|
||||||
run_procs!(config)
|
run_procs!(config)
|
||||||
config.loaded!
|
config.loaded!
|
||||||
|
config
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -78,6 +78,12 @@ class ConfigTest < Test::Unit::TestCase
|
||||||
Vagrant::Config.execute!
|
Vagrant::Config.execute!
|
||||||
assert Vagrant::Config.config.loaded?
|
assert Vagrant::Config.config.loaded?
|
||||||
end
|
end
|
||||||
|
|
||||||
|
should "return the configuration on execute!" do
|
||||||
|
Vagrant::Config.run {}
|
||||||
|
result = Vagrant::Config.execute!
|
||||||
|
assert result.equal?(Vagrant.config)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
context "base class" do
|
context "base class" do
|
||||||
|
|
Loading…
Reference in New Issue