diff test_pymonkey.py @ 2:2f6bdc9f7245

pymonkey.evaluate() now returns a python-ized version of the JS return value, though it only supports integers at the moment.
author Atul Varma <varmaa@toolness.com>
date Sun, 28 Jun 2009 12:26:46 -0700
parents 21aa6e3abb49
children d6a0819ca6ca
line wrap: on
line diff
--- a/test_pymonkey.py	Sun Jun 28 12:02:52 2009 -0700
+++ b/test_pymonkey.py	Sun Jun 28 12:26:46 2009 -0700
@@ -3,7 +3,8 @@
 
 class PymonkeyTests(unittest.TestCase):
     def test_evaluate(self):
-        pymonkey.evaluate('1+3', '<string>', 1)
+        self.assertEqual(pymonkey.evaluate('1+3', '<string>', 1),
+                         4)
 
 if __name__ == '__main__':
     unittest.main()