diff options
Diffstat (limited to 'Lib/test/test_ast.py')
-rw-r--r-- | Lib/test/test_ast.py | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Lib/test/test_ast.py b/Lib/test/test_ast.py index 366269f..2f59527 100644 --- a/Lib/test/test_ast.py +++ b/Lib/test/test_ast.py @@ -532,6 +532,7 @@ class ASTHelpers_Test(unittest.TestCase): node = ast.parse('async def foo():\n """spam\n ham"""') self.assertEqual(ast.get_docstring(node.body[0]), 'spam\nham') + self.assertIsNone(ast.get_docstring(ast.parse(''))) def test_literal_eval(self): self.assertEqual(ast.literal_eval('[1, 2, 3]'), [1, 2, 3]) |