Skip to content

Commit

Permalink
debug() test more robust
Browse files Browse the repository at this point in the history
  • Loading branch information
tschorr committed Oct 3, 2018
1 parent b999c20 commit 87e9b59
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions src/Zope2/utilities/tests/test_zconsole.py
Expand Up @@ -3,7 +3,6 @@
import sys
import tempfile
import unittest
from subprocess import Popen, PIPE, TimeoutExpired

zope_conf_template = """
%define INSTANCE {}
Expand Down Expand Up @@ -38,14 +37,6 @@ def setUp(self):
conffile.write(zope_conf_template.format(self.instancedir))

def test_debug(self):
with Popen(sys.executable, shell=True, stdin=PIPE, stdout=PIPE, stderr=PIPE) as test: # noqa: E501
test.stdin.write(
bytes('from Zope2.utilities.zconsole import debug; app = debug("{}")\n'.format( # noqa: E501
self.zopeconf).encode('ascii')))
try:
got, errs = test.communicate(b'print(app)\n', timeout=1)
except TimeoutExpired:
test.kill()
stored_sys_argv = sys.argv
stored_stdout = sys.stdout
try:
Expand Down

0 comments on commit 87e9b59

Please sign in to comment.