def test_generate_debian_os_release(self): for distro in ["jessie", "stretch", "???"]: output_file = StringIO.StringIO() util.generate_os_release(distro, output_file) self.assertEqual(osReleaseForDistro[distro], output_file.getvalue())
def test_generate_debian_os_release(self): for distro, expected_output in osReleaseForDistro.items(): output_file = StringIO() util.generate_os_release(distro, output_file) self.assertEqual(expected_output, output_file.getvalue())