diff options
author | Zachary Ware <zachary.ware@gmail.com> | 2015-10-13 04:30:15 (GMT) |
---|---|---|
committer | Zachary Ware <zachary.ware@gmail.com> | 2015-10-13 04:30:15 (GMT) |
commit | fa10f61ee54892cc9fc7e08c01dec06f37522156 (patch) | |
tree | 40d839858d0624beaf6c3384b755e708d7704822 /Lib | |
parent | 50856d5ae745d1c9f691afbd78572bf073c941cf (diff) | |
parent | 83fd0a81a4afff60339b0ead31c3b8317b29fd55 (diff) | |
download | cpython-fa10f61ee54892cc9fc7e08c01dec06f37522156.zip cpython-fa10f61ee54892cc9fc7e08c01dec06f37522156.tar.gz cpython-fa10f61ee54892cc9fc7e08c01dec06f37522156.tar.bz2 |
Issue #25093: Merge with 3.4
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/test/test_tcl.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Lib/test/test_tcl.py b/Lib/test/test_tcl.py index 5be645a..25f6ede 100644 --- a/Lib/test/test_tcl.py +++ b/Lib/test/test_tcl.py @@ -1,5 +1,6 @@ import unittest import re +import subprocess import sys import os from test import support @@ -242,11 +243,10 @@ class TclTest(unittest.TestCase): with support.EnvironmentVarGuard() as env: env.unset("TCL_LIBRARY") - f = os.popen('%s -c "import tkinter; print(tkinter)"' % (unc_name,)) + stdout = subprocess.check_output( + [unc_name, '-c', 'import tkinter; print(tkinter)']) - self.assertIn('tkinter', f.read()) - # exit code must be zero - self.assertEqual(f.close(), None) + self.assertIn(b'tkinter', stdout) def test_exprstring(self): tcl = self.interp |