From: Antoine Pitrou Date: Tue, 6 Aug 2013 21:05:23 +0000 (+0200) Subject: Issue #18666: improve test_frame a bit. Patch by Vajrasky Kok. X-Git-Tag: v3.4.0a2~282 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=dbfc129cc8f2a3ea3e6a0b7e6492887212923bc6;p=python Issue #18666: improve test_frame a bit. Patch by Vajrasky Kok. --- diff --git a/Lib/test/test_frame.py b/Lib/test/test_frame.py index daabba801b..f42dad342c 100644 --- a/Lib/test/test_frame.py +++ b/Lib/test/test_frame.py @@ -90,6 +90,9 @@ class ClearTest(unittest.TestCase): gen = g() f = next(gen) self.assertFalse(endly) + # Clearing the frame closes the generator + f.clear() + self.assertTrue(endly) @support.cpython_only def test_clear_refcycles(self):