Skip to content

Commit

Permalink
Remove skipping validation in our CIs
Browse files Browse the repository at this point in the history
  • Loading branch information
ccordoba12 committed May 23, 2018
1 parent 39c11f1 commit edf2e47
Showing 1 changed file with 15 additions and 19 deletions.
34 changes: 15 additions & 19 deletions winpty/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,6 @@

# yapf: disable

# Standard library imports
import os

# Local imports
from .ptyprocess import PtyProcess
from .winpty_wrapper import PTY
Expand All @@ -24,19 +21,18 @@
# Test that spawing a process is working or raise
# an ImportError.
# Fixes issue 59
if os.environ.get('CI') is None:
for _ in range(10): # Sometimes it doesn't fail the first time
valid = False
try:
proc = PtyProcess.spawn('python')
proc.write('print("hello, world!")\r\n')
proc.write('exit()\r\n')
valid = True
except Exception:
break

if not valid:
raise ImportError('Cannot successfully read from pty, see '
'https://github.com/spyder-ide/pywinpty/issues/59')

del proc, valid
for _ in range(10): # Sometimes it doesn't fail the first time
valid = False
try:
proc = PtyProcess.spawn('python')
proc.write('print("hello, world!")\r\n')
proc.write('exit()\r\n')
valid = True
except Exception:
break

if not valid:
raise ImportError('Cannot successfully read from pty, see '
'https://github.com/spyder-ide/pywinpty/issues/59')

del proc, valid

0 comments on commit edf2e47

Please sign in to comment.