def test_to_toml_file(self): d = IODict({ 'x': 7, 'y': 8, 'z': 9, 'a': 1, 'b': 2, 'c': 3, }) filepath = self.output_path('test_to_toml_file.toml') d.to_toml(filepath=filepath) self.assertFileExists(filepath) self.assertEqual(d, IODict.from_toml(filepath))
def test_to_toml(self): d = IODict({ 'x': 7, 'y': 8, 'z': 9, 'a': 1, 'b': 2, 'c': 3, }) s = d.to_toml() self.assertEqual(d, IODict.from_toml(s))