Skip to content

Commit

Permalink
Add nil IP address check to preflight check
Browse files Browse the repository at this point in the history
  • Loading branch information
fabiendupont committed Jan 31, 2019
1 parent 6752229 commit cf83a9b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion app/models/service_template_transformation_plan_task.rb
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ def task_active
def preflight_check
destination_cluster
virtv2v_disks
network_mappings
network_mappings.each { |m| raise if m.ip_address.nil? }
raise if destination_ems.emstype == 'openstack' && source.power_state == 'off'
true
rescue
Expand Down
4 changes: 4 additions & 0 deletions spec/models/service_template_transformation_plan_task_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -453,6 +453,8 @@
)
end

it { expect(task_1.preflight_check). to be false }

context "transport method is vddk" do
before do
conversion_host.vddk_transport_supported = true
Expand Down Expand Up @@ -542,6 +544,8 @@
)
end

it { expect(task_1.preflight_check). to be false }

context "transport method is vddk" do
before do
conversion_host.vddk_transport_supported = true
Expand Down

0 comments on commit cf83a9b

Please sign in to comment.