]> granicus.if.org Git - clang/commitdiff
Driver: Tighten up crash report tests
authorJustin Bogner <mail@justinbogner.com>
Tue, 21 Oct 2014 05:13:09 +0000 (05:13 +0000)
committerJustin Bogner <mail@justinbogner.com>
Tue, 21 Oct 2014 05:13:09 +0000 (05:13 +0000)
These tests were a little bit too flexible in terms of filenames.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@220265 91177308-0d34-0410-b5e6-96231b3b80d8

test/Driver/crash-report-null.test [new file with mode: 0644]
test/Driver/crash-report.c

diff --git a/test/Driver/crash-report-null.test b/test/Driver/crash-report-null.test
new file mode 100644 (file)
index 0000000..477dd28
--- /dev/null
@@ -0,0 +1,7 @@
+// RUN: not env FORCE_CLANG_DIAGNOSTICS_CRASH=1 %clang -fsyntax-only -x c /dev/null -lstdc++ 2>&1 | FileCheck %s
+
+// FIXME: Investigating. "fatal error: file 'nul' modified since it was first processed"
+// XFAIL: mingw32
+
+// CHECK: Preprocessed source(s) and associated run script(s) are located at:
+// CHECK-NEXT: note: diagnostic msg: {{.*}}null-{{.*}}.c
index da1ff950fb9a6ba23c00e14e3b0af4b52aef754a..f407a08e96fb0a2781e1dd35c09048010c4e3080 100644 (file)
 // because of the glob (*.c, *.sh)
 // REQUIRES: shell
 
-// RUN: not env FORCE_CLANG_DIAGNOSTICS_CRASH=1 %clang -fsyntax-only -x c /dev/null -lstdc++ 2>&1 | FileCheck %s
-
-// FIXME: Investigating. "fatal error: file 'nul' modified since it was first processed"
-// XFAIL: mingw32
-
 #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: {{.*}}crash-report-{{.*}}.c
 FOO
 // CHECKSRC: FOO
 // CHECKSH: -cc1
+// CHECKSH: -main-file-name crash-report.c
 // CHECKSH: -D "FOO=BAR"
 // CHECKSH-NOT: -F/tmp/
 // CHECKSH-NOT: -I /tmp/