diff options
author | Thomas Kluyver <takowl@gmail.com> | 2013-09-25 16:26:33 -0700 |
---|---|---|
committer | Thomas Kluyver <takowl@gmail.com> | 2013-09-25 16:26:33 -0700 |
commit | 8f2cdbbdd285d81b00f49f07351776b3d6ab7a8e (patch) | |
tree | 84d833dc542837167df4db4a5a3ebf6a7e300960 /tests/test_interact.py | |
parent | c6166a02a7f28cfbac9d2bd4488c1b354f641da6 (diff) | |
download | pexpect-git-8f2cdbbdd285d81b00f49f07351776b3d6ab7a8e.tar.gz |
Remove skipped test_interact_thread
Diffstat (limited to 'tests/test_interact.py')
-rwxr-xr-x | tests/test_interact.py | 30 |
1 files changed, 0 insertions, 30 deletions
diff --git a/tests/test_interact.py b/tests/test_interact.py index e850478..5d071d5 100755 --- a/tests/test_interact.py +++ b/tests/test_interact.py @@ -21,40 +21,10 @@ PEXPECT LICENSE ''' import pexpect import unittest -import time, tty import PexpectTestCase -import threading - -def start_interact (p): - p.interact() class InteractTestCase (PexpectTestCase.PexpectTestCase): - def test_interact_thread (self): - # I can't believe this actually works... - # ...it doesn't! And I can't work out what it's testing (TK, Sep 2013) - return "SKIP" - - # Note that I had to add a delay in the swapcase_echo.py script. - # I'm not sure why this helped. - p = pexpect.spawn('%s swapcase_echo.py' % (self.PYTHONBIN,)) - mode = tty.tcgetattr(p.STDIN_FILENO) - t = threading.Thread (target=start_interact, args=(p,)) - t.start() - #thread.start_new_thread (start_interact, (p,)) - time.sleep(1) - p.sendline ('Hello') - #time.sleep(1) - try: - p.expect ('hELLO', timeout=4) - except Exception: - p.close(force = False) - tty.tcsetattr(p.STDIN_FILENO, tty.TCSAFLUSH, mode) - #print(str(p)) - raise - p.close(force = True) - tty.tcsetattr(p.STDIN_FILENO, tty.TCSAFLUSH, mode) - def test_interact (self): p = pexpect.spawn('%s interact.py' % (self.PYTHONBIN,)) p.sendline (b'Hello') |