diff --git a/llvm/utils/lit/lit/TestRunner.py b/llvm/utils/lit/lit/TestRunner.py --- a/llvm/utils/lit/lit/TestRunner.py +++ b/llvm/utils/lit/lit/TestRunner.py @@ -894,10 +894,6 @@ out = err = '' for i,result in enumerate(results): - # Write the command line run. - out += '$ %s\n' % (' '.join('"%s"' % s - for s in result.command.args),) - # If nothing interesting happened, move on. if litConfig.maxIndividualTestTime == 0 and \ result.exitCode == 0 and \ @@ -905,25 +901,10 @@ continue # Otherwise, something failed or was printed, show it. - - # Add the command output, if redirected. - for (name, path, data) in result.outputFiles: - if data.strip(): - out += "# redirected output from %r:\n" % (name,) - data = to_string(data.decode('utf-8', errors='replace')) - if len(data) > 1024: - out += data[:1024] + "\n...\n" - out += "note: data was truncated\n" - else: - out += data - out += "\n" - if result.stdout.strip(): - out += '# command output:\n%s\n' % (result.stdout,) + out += result.stdout if result.stderr.strip(): - out += '# command stderr:\n%s\n' % (result.stderr,) - if not result.stdout.strip() and not result.stderr.strip(): - out += "note: command had no output on stdout or stderr\n" + err += result.stderr # Show the error conditions: if result.exitCode != 0: @@ -933,10 +914,10 @@ codeStr = hex(int(result.exitCode & 0xFFFFFFFF)).rstrip("L") else: codeStr = str(result.exitCode) - out += "error: command failed with exit status: %s\n" % ( + err += "\nerror: command failed with exit status: %s\n" % ( codeStr,) if litConfig.maxIndividualTestTime > 0 and result.timeoutReached: - out += 'error: command reached timeout: %s\n' % ( + err += '\nerror: command reached timeout: %s\n' % ( str(result.timeoutReached),) return out, err, exitCode, timeoutInfo