Mercurial > pymonkey
view 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 source
import unittest import pymonkey class PymonkeyTests(unittest.TestCase): def test_evaluate(self): self.assertEqual(pymonkey.evaluate('1+3', '<string>', 1), 4) if __name__ == '__main__': unittest.main()