Issue #25322: Merge contextlib.suppress test fix from 3.4 into 3.5

This commit is contained in:
Martin Panter 2015-10-10 11:05:47 +00:00
commit 05da525e55
1 changed files with 3 additions and 1 deletions

View File

@ -880,9 +880,11 @@ class TestSuppress(unittest.TestCase):
with ignore_exceptions:
len(5)
with ignore_exceptions:
1/0
with ignore_exceptions: # Check nested usage
len(5)
outer_continued = True
1/0
self.assertTrue(outer_continued)
if __name__ == "__main__":
unittest.main()