Python 2.6 compat : don't use assertRaises as a context manager