Add base address attribute to vm config
This commit is contained in:
parent
87214ed840
commit
61cf179b42
|
@ -20,6 +20,7 @@ module VagrantPlugins
|
|||
|
||||
attr_accessor :allowed_synced_folder_types
|
||||
attr_accessor :base_mac
|
||||
attr_accessor :base_address
|
||||
attr_accessor :boot_timeout
|
||||
attr_accessor :box
|
||||
attr_accessor :ignore_box_vagrantfile
|
||||
|
@ -50,6 +51,7 @@ module VagrantPlugins
|
|||
|
||||
@allowed_synced_folder_types = UNSET_VALUE
|
||||
@base_mac = UNSET_VALUE
|
||||
@base_address = UNSET_VALUE
|
||||
@boot_timeout = UNSET_VALUE
|
||||
@box = UNSET_VALUE
|
||||
@ignore_box_vagrantfile = UNSET_VALUE
|
||||
|
@ -377,6 +379,7 @@ module VagrantPlugins
|
|||
# Defaults
|
||||
@allowed_synced_folder_types = nil if @allowed_synced_folder_types == UNSET_VALUE
|
||||
@base_mac = nil if @base_mac == UNSET_VALUE
|
||||
@base_address = nil if @base_address == UNSET_VALUE
|
||||
@boot_timeout = 300 if @boot_timeout == UNSET_VALUE
|
||||
@box = nil if @box == UNSET_VALUE
|
||||
@ignore_box_vagrantfile = false if @ignore_box_vagrantfile == UNSET_VALUE
|
||||
|
|
|
@ -52,6 +52,13 @@ describe VagrantPlugins::Kernel_V2::VMConfig do
|
|||
end
|
||||
end
|
||||
|
||||
describe "#base_address" do
|
||||
it "defaults properly" do
|
||||
subject.finalize!
|
||||
expect(subject.base_address).to be_nil
|
||||
end
|
||||
end
|
||||
|
||||
describe "#box" do
|
||||
it "is required" do
|
||||
subject.box = nil
|
||||
|
|
Loading…
Reference in New Issue