unittest.assertRaises is a context manager only since python 2.7