def METHOD_NAME(self):
    self.generic_parameters_str.write_file(
        file_name="genpar.txt", cwd=self.file_location
    )
    file_name = os.path.join(self.file_location, "genpar.txt")
    with open(file_name, "r") as f:
        lines = f.readlines()
    self.assertEqual(lines[0], "par 1 1\n")
    self.assertEqual(lines[1], "par_2 all\n")
    self.assertEqual(lines[2], "count 0\n")
    self.assertEqual(lines[3], "write_restart True\n")
    self.assertEqual(lines[4], "dict {'a': 1, 'b': 2}\n")
    self.assertEqual(lines[5], "list [1, 's']\n")
    self.assertEqual(lines[6], "read_restart False\n")
    os.remove(file_name)