Fix IntField assignment unit tests

This commit is contained in:
Thomas Steinacher 2013-06-18 18:31:11 -07:00
commit 2a93a69085
3 changed files with 6 additions and 13 deletions

View file

@ -134,13 +134,8 @@ class ValidatorErrorTest(unittest.TestCase):
self.assertTrue('e' in keys)
self.assertTrue('id' in keys)
doc.e.val = "OK"
try:
doc.save()
except ValidationError, e:
self.assertTrue("Doc:test" in e.message)
self.assertEqual(e.to_dict(), {
"e": {'val': 'OK could not be converted to int'}})
with self.assertRaises(ValueError):
doc.e.val = "OK"
if __name__ == '__main__':