diff options
| author | David Blaikie <dblaikie@gmail.com> | 2012-07-02 22:07:20 +0000 |
|---|---|---|
| committer | David Blaikie <dblaikie@gmail.com> | 2012-07-02 22:07:20 +0000 |
| commit | a6b4db812c0fcf18be414dc97338573ab58d8954 (patch) | |
| tree | 3a34ea9e356d29d2a94e52f04ab8d3234597b106 | |
| parent | 1f5181aa45d4d65901e56befe953d9b307e8179f (diff) | |
| download | bcm5719-llvm-a6b4db812c0fcf18be414dc97338573ab58d8954.tar.gz bcm5719-llvm-a6b4db812c0fcf18be414dc97338573ab58d8954.zip | |
Improve crash reporting test coverage.
This adds validation that the
* repro source is only rewrite-includes processed, not fully preprocessed.
* repro script contains macro definitions (-DFOO=BAR).
Based on suggestions/help by Matt Beaumont-Gay.
llvm-svn: 159605
| -rw-r--r-- | clang/test/Driver/crash-report.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/clang/test/Driver/crash-report.c b/clang/test/Driver/crash-report.c index 9ec32081404..75340035dd5 100644 --- a/clang/test/Driver/crash-report.c +++ b/clang/test/Driver/crash-report.c @@ -1,7 +1,13 @@ -// RUN: %clang -fsyntax-only %s 2>&1 | FileCheck %s +// RUN: rm %T/crash-report-*.c %T/crash-report-*.sh +// RUN: TMP=%T %clang -fsyntax-only %s -DFOO=BAR 2>&1 | FileCheck %s +// RUN: FileCheck --check-prefix=CHECKSRC %s < %T/crash-report-*.c +// RUN: FileCheck --check-prefix=CHECKSH %s < %T/crash-report-*.sh // REQUIRES: crash-recovery // XFAIL: mingw32,win32 #pragma clang __debug parser_crash // CHECK: Preprocessed source(s) and associated run script(s) are located at: -// CHECK-NEXT: {{.*}}: note: diagnostic msg: {{.*}}.c +// CHECK-NEXT: note: diagnostic msg: {{.*}}.c +FOO +// CHECKSRC: FOO +// CHECKSH: -D FOO=BAR |

