From 53fca106981aa3c8ee9576041ebdab4d2c691cfa Mon Sep 17 00:00:00 2001 From: Yongqin Liu Date: Thu, 17 May 2018 19:07:39 +0800 Subject: tradefed-runner.py: set searchwindowsize for pexpect.spawn to work around the timed out problem when run cts opengl test did not find the root cause yet, so set searchwindowsize to 1024 might not very accurate. When tested on local side, it could help to finish CtsDeqpTestCases module less than 90 minutes, so this should help on the opgengl timed out problem on lava Change-Id: I9507bc09e1336ed7f41514ba241d9e939ea074e4 Signed-off-by: Yongqin Liu --- automated/android/tradefed/tradefed-runner.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/automated/android/tradefed/tradefed-runner.py b/automated/android/tradefed/tradefed-runner.py index b5e966c..36172fc 100755 --- a/automated/android/tradefed/tradefed-runner.py +++ b/automated/android/tradefed/tradefed-runner.py @@ -204,7 +204,7 @@ if command == 'android-vts/tools/vts-tradefed' and \ monitor_cmd = 'android-vts/testcases/vts/script/monitor-runner-output.py -m' monitor_vts_output = subprocess.Popen(shlex.split(monitor_cmd), stderr=subprocess.STDOUT, stdout=vts_run_details) -child = pexpect.spawn(command, logfile=tradefed_stdout) +child = pexpect.spawn(command, logfile=tradefed_stdout, searchwindowsize=1024) try: child.expect(prompt, timeout=60) child.sendline(args.TEST_PARAMS) @@ -244,11 +244,12 @@ while child.isalive(): m = child.expect(['ResultReporter: Full Result:', 'ConsoleReporter:.*Test run failed to complete.', pexpect.TIMEOUT], + searchwindowsize=1024, timeout=60) # Once all tests finshed, exit from tf shell to throw EOF, which sets child.isalive() to false. if m == 0: try: - child.expect(prompt, timeout=60) + child.expect(prompt, searchwindowsize=1024, timeout=60) logger.debug('Sending "exit" command to TF shell...') child.sendline('exit') child.expect(pexpect.EOF, timeout=60) -- cgit v1.2.3