Commit f2582500 authored by Dylan Trotter's avatar Dylan Trotter Committed by Dylan Trotter

Prefer ast.literal_eval() to eval().

parent 0e50a4ea
......@@ -39,7 +39,7 @@ def _MakeLiteralTest(lit):
def Test(self):
status, output = _GrumpRun('print repr({!r}),'.format(lit))
self.assertEqual(0, status, output)
self.assertEqual(lit, eval(output)) # pylint: disable=eval-used
self.assertEqual(lit, ast.literal_eval(output))
return Test
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment