pos might be undefined

This commit is contained in:
Loic Nageleisen 2014-01-26 13:06:23 +01:00
parent 457e24fb31
commit ba160588a0
2 changed files with 8 additions and 2 deletions

View file

@ -36,6 +36,9 @@ class TestParser(TestCase):
self.assertEqual(str(parser.parse("(+ '1 (* 3 2))")),
"(+ . ('1 . ((* . (3 . (2 . NIL))) . NIL)))")
def test_error_unclosed_list(self):
self.assertRaises(ValueError, parser.parse("(42"))
if __name__ == '__main__':
import unittest