diff options
| author | Antoine Pitrou <solipsis@pitrou.net> | 2014-02-23 19:41:51 +0100 |
|---|---|---|
| committer | Antoine Pitrou <solipsis@pitrou.net> | 2014-02-23 19:41:51 +0100 |
| commit | 8a14ea46940b3000f8a56d246ae5c220845b759a (patch) | |
| tree | 12314928d6d4c6f7d18737053b84ab9a4edbbc0b /Lib/test/test_tcl.py | |
| parent | 27519673d3ca0d265d719233e6a43f1afa3fe2fc (diff) | |
| parent | 220cc21cec3716ca94d63fea51d30ae84274d8cc (diff) | |
| download | cpython-git-8a14ea46940b3000f8a56d246ae5c220845b759a.tar.gz | |
Issue #20743: Fix a reference leak in test_tcl.
Diffstat (limited to 'Lib/test/test_tcl.py')
| -rw-r--r-- | Lib/test/test_tcl.py | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Lib/test/test_tcl.py b/Lib/test/test_tcl.py index c0c6341c92..d12fb22484 100644 --- a/Lib/test/test_tcl.py +++ b/Lib/test/test_tcl.py @@ -376,6 +376,7 @@ class TclTest(unittest.TestCase): result = arg return arg self.interp.createcommand('testfunc', testfunc) + self.addCleanup(self.interp.tk.deletecommand, 'testfunc') def check(value, expected, eq=self.assertEqual): r = self.interp.call('testfunc', value) self.assertIsInstance(result, str) |
