summaryrefslogtreecommitdiff
path: root/test/Misc/message-length.c
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2009-10-19 06:45:49 +0000
committerChris Lattner <sabre@nondot.org>2009-10-19 06:45:49 +0000
commitacfd65d0db825dbc9d4912abca6c84b3192820cd (patch)
tree247edb1648403d291068cff7d146a4349ddb2c01 /test/Misc/message-length.c
parentc575ce7287ed9b5a2657aa0079595ebb59490afb (diff)
downloadclang-acfd65d0db825dbc9d4912abca6c84b3192820cd.tar.gz
convert this to FileCheck, PR5232
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@84466 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Misc/message-length.c')
-rw-r--r--test/Misc/message-length.c15
1 files changed, 6 insertions, 9 deletions
diff --git a/test/Misc/message-length.c b/test/Misc/message-length.c
index ac5dab99ca..69a5c1c191 100644
--- a/test/Misc/message-length.c
+++ b/test/Misc/message-length.c
@@ -1,14 +1,7 @@
-// RUN: clang -fsyntax-only -fmessage-length=72 %s 2> %t &&
-
-// RUN: grep -A4 "FILE:23" %t > %t.msg &&
-// FIXME: This diagnostic is getting truncated very poorly.
-// RUN: grep -e '^ ...// some long comment text and a brace, eh {} ' %t.msg &&
-// RUN: grep -e '^ \^' %t.msg &&
-// RUN: clang -fsyntax-only -fmessage-length=1 %s &&
-// RUN: true
+// RUN: clang -fsyntax-only -fmessage-length=72 %s 2>&1 | tee /tmp/out.txt | FileCheck -strict-whitespace %s &&
+// RUN: clang -fsyntax-only -fmessage-length=1 %s
// Hack so we can check things better, force the file name and line.
-
# 1 "FILE" 1
/* It's tough to verify the results of this test mechanically, since
@@ -33,3 +26,7 @@ void a_very_long_line(int *ip, float *FloatPointer) {
}
#pragma STDC CX_LIMITED_RANGE // some long comment text and a brace, eh {}
+
+
+// CHECK: FILE:23:78
+// CHECK: {{^ ...some long comment text and a brace, eh {} $}}