Message186634
with self.assertRaises(KeyError) as cm:
os.environ[missing]
self.assertEqual(cm.excecption.args[0], missing)
(I don't know why assertRaises returns itself rather than just returning the exception in the with, but that's the API). |
|
Date |
User |
Action |
Args |
2013-04-12 14:09:38 | r.david.murray | set | recipients:
+ r.david.murray, vstinner, Robert.Tasarz |
2013-04-12 14:09:38 | r.david.murray | set | messageid: <1365775778.35.0.582838152028.issue17702@psf.upfronthosting.co.za> |
2013-04-12 14:09:38 | r.david.murray | link | issue17702 messages |
2013-04-12 14:09:38 | r.david.murray | create | |
|