Do not wait, just .read()

.read() without arguments should read until EOF is received.
This commit is contained in:
ZyX 2015-02-21 16:58:39 +03:00
parent 0a87b558d9
commit 7d98218b64
1 changed files with 0 additions and 10 deletions

View File

@ -12,8 +12,6 @@ from io import BytesIO
import pexpect
from powerline.lib.monotonic import monotonic
def get_argparser(ArgumentParser=argparse.ArgumentParser):
parser = ArgumentParser(description='Run powerline shell test using pexpect')
@ -98,14 +96,6 @@ def main():
sleep(1)
# TODO Implement something more smart
start = monotonic()
while child.isalive():
sleep(0.1)
if monotonic() - start > 60 * 3:
# Waiting for three minutes. This is long enough.
child.kill()
break
with open(full_log_file_name, 'wb') as LF:
LF.write(child.read())