def test_sum_cpu_resources_example_list_with_mixed(): cpu_resources = ["30m", "40m", "700m", None, "700m", "33m", "1", "2.5"] expected_result = "5003m" result = view.sum_cpu_resources(cpu_resources) assert result == expected_result
def test_sum_cpu_resources_example_list(): cpu_resources = ["30m", "40m", "700m"] expected_result = "770m" result = view.sum_cpu_resources(cpu_resources) assert result == expected_result
def test_sum_cpu_resources_example_list_with_none(): cpu_resources = ["30m", "40m", "700m", None, "700m", "33m"] expected_result = "1503m" result = view.sum_cpu_resources(cpu_resources) assert result == expected_result
def test_sum_cpu_resources_empty_list(): cpu_resources = [] expected_result = "0m" result = view.sum_cpu_resources(cpu_resources) assert result == expected_result