diff --git a/app/models/manageiq/providers/lenovo/physical_infra_manager/parsers/components/physical_server_parser.rb b/app/models/manageiq/providers/lenovo/physical_infra_manager/parsers/components/physical_server_parser.rb index b803ef0e62..979c6af24b 100644 --- a/app/models/manageiq/providers/lenovo/physical_infra_manager/parsers/components/physical_server_parser.rb +++ b/app/models/manageiq/providers/lenovo/physical_infra_manager/parsers/components/physical_server_parser.rb @@ -57,7 +57,7 @@ def get_disk_capacity(node) total_disk_cap += disk['capacity'] unless disk['capacity'].nil? end end - total_disk_cap + total_disk_cap > 0 ? total_disk_cap : nil end def get_memory_info(node) diff --git a/spec/models/manageiq/providers/lenovo/physical_infra_manager/refresh_parser_spec.rb b/spec/models/manageiq/providers/lenovo/physical_infra_manager/refresh_parser_spec.rb index fc4e4efb41..64da9e4f29 100644 --- a/spec/models/manageiq/providers/lenovo/physical_infra_manager/refresh_parser_spec.rb +++ b/spec/models/manageiq/providers/lenovo/physical_infra_manager/refresh_parser_spec.rb @@ -86,7 +86,7 @@ computer_system = physical_server[:computer_system] hardware = computer_system[:hardware] - expect(hardware[:disk_capacity]).to eq(0) + expect(hardware[:disk_capacity]).to be_nil end end