From 31e446c3db9031f69641c8ce7be8e396aeb60caa Mon Sep 17 00:00:00 2001 From: Steve Block Date: Fri, 20 May 2011 17:39:30 +0100 Subject: Add extra error handling to DRT2 launcher script Bug: 3291220 Change-Id: I6f8e57458cd4334a998eb256af303ffcd9c50d64 --- tests/DumpRenderTree2/assets/run_layout_tests.py | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'tests') diff --git a/tests/DumpRenderTree2/assets/run_layout_tests.py b/tests/DumpRenderTree2/assets/run_layout_tests.py index 3b8c09a..161416a 100755 --- a/tests/DumpRenderTree2/assets/run_layout_tests.py +++ b/tests/DumpRenderTree2/assets/run_layout_tests.py @@ -44,9 +44,15 @@ def main(path, options): logging.info("Running the tests...") logging.debug("Command = %s" % cmd) (stdoutdata, stderrdata) = subprocess.Popen(cmd, shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE).communicate() + if stderrdata != "": + logging.info("Failed to start tests:\n%s", stderrdata) + return if re.search("^INSTRUMENTATION_STATUS_CODE: -1", stdoutdata, re.MULTILINE) != None: logging.info("Failed to run the tests. Is DumpRenderTree2 installed on the device?") return + if re.search("^OK \([0-9]+ tests?\)", stdoutdata, re.MULTILINE) == None: + logging.info("DumpRenderTree2 failed to run correctly:\n%s", stdoutdata) + return logging.info("Downloading the summaries...") -- cgit v1.1