mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-23 11:13:28 +01:00
3204e36001
(Relands r333584, reverted in 333592.) When debugging test failures with -vv (or -v in the case of the internal shell), this makes it easier to locate the RUN line that failed. For example, clang's test/Driver/linux-ld.c has 892 total RUN lines, and clang's test/Driver/arm-cortex-cpus.c has 424 RUN lines after concatenation for line continuations. When reading the generated shell script, this also makes it easier to locate the RUN line that produced each command. To support reporting RUN line numbers in the case of the internal shell, this patch extends the internal shell to support the null command, ":", except pipelines are not supported. To support reporting RUN line numbers in the case of windows cmd.exe as the external shell, this patch extends -vv to set "echo on" instead of "echo off" in bat files. (Support for windows cmd.exe as a lit external shell will likely be dropped later, but I found out too late.) Reviewed By: delcypher, asmith, stella.stamenova, jmorse, lebedev.ri, rnk Differential Revision: https://reviews.llvm.org/D44598 llvm-svn: 333614
32 lines
947 B
Python
32 lines
947 B
Python
# Check the various features of the ShTest format.
|
|
#
|
|
# RUN: not %{lit} -j 1 -v %{inputs}/shtest-output-printing > %t.out
|
|
# RUN: FileCheck --input-file %t.out %s
|
|
#
|
|
# END.
|
|
|
|
# CHECK: -- Testing:
|
|
|
|
# CHECK: FAIL: shtest-output-printing :: basic.txt
|
|
# CHECK-NEXT: *** TEST 'shtest-output-printing :: basic.txt' FAILED ***
|
|
# CHECK-NEXT: Script:
|
|
# CHECK-NEXT: --
|
|
# CHECK: --
|
|
# CHECK-NEXT: Exit Code: 1
|
|
#
|
|
# CHECK: Command Output
|
|
# CHECK-NEXT: --
|
|
# CHECK-NEXT: $ ":" "RUN: at line 1"
|
|
# CHECK-NEXT: $ "true"
|
|
# CHECK-NEXT: $ ":" "RUN: at line 2"
|
|
# CHECK-NEXT: $ "echo" "hi"
|
|
# CHECK-NEXT: # command output:
|
|
# CHECK-NEXT: hi
|
|
#
|
|
# CHECK: $ ":" "RUN: at line 3"
|
|
# CHECK-NEXT: $ "wc" "missing-file"
|
|
# CHECK-NEXT: # redirected output from '{{.*(/|\\\\)}}basic.txt.tmp.out':
|
|
# CHECK-NEXT: missing-file{{.*}} No such file or directory
|
|
# CHECK: note: command had no output on stdout or stderr
|
|
# CHECK-NEXT: error: command failed with exit status: 1
|