2 from __future__ import absolute_import, print_function
4 from bup.compat import pending_raise
5 from wvpytest import wvpasseq
7 def test_pending_raise():
8 outer = Exception('outer')
9 inner = Exception('inner')
14 except Exception as ex:
15 with pending_raise(ex):
17 except Exception as ex:
19 wvpasseq(None, getattr(outer, '__context__', None))
24 except Exception as ex:
25 with pending_raise(ex):
27 except Exception as ex:
29 wvpasseq(None, getattr(outer, '__context__', None))
30 wvpasseq(outer, getattr(inner, '__context__', None))