Exemplo n.º 1
0
 def testParseNumber(self):
     assert(minilisp.parse("3") == 3)
Exemplo n.º 2
0
 def testParseNested(self):
     assert(minilisp.parse("(+ 3 (+ 4 5))") == ['+', 3, ['+', 4, 5]])
Exemplo n.º 3
0
 def testParseEmpty(self):
     assert(minilisp.parse('') == [])
Exemplo n.º 4
0
 def testParse(self):
     self.assertEqual(3, minilisp.parse("3"))
     self.assertEqual('x', minilisp.parse("x"))
     self.assertEqual(['+', 'x', 'y'], minilisp.parse("(+ x y)"))
Exemplo n.º 5
0
 def testParseExpr(self):
     assert(minilisp.parse("(+ 3 4)") == ['+', 3, 4])
Exemplo n.º 6
0
 def testParse(self):
     self.assertEqual(3, minilisp.parse("3"))
     self.assertEqual('x', minilisp.parse("x"))
     self.assertEqual(['+', 'x', 'y'], minilisp.parse("(+ x y)"))
Exemplo n.º 7
0
 def testParseEmpty(self):
     assert (minilisp.parse('') == [])
Exemplo n.º 8
0
 def testParseNested(self):
     assert (minilisp.parse("(+ 3 (+ 4 5))") == ['+', 3, ['+', 4, 5]])
Exemplo n.º 9
0
 def testParseExpr(self):
     assert (minilisp.parse("(+ 3 4)") == ['+', 3, 4])
Exemplo n.º 10
0
 def testParseNumber(self):
     assert (minilisp.parse("3") == 3)