]> granicus.if.org Git - clang/commitdiff
Fix dependency generation crash test to run clang and clean up after itself.
authorGreg Bedwell <greg_bedwell@sn.scee.net>
Thu, 12 Feb 2015 12:41:28 +0000 (12:41 +0000)
committerGreg Bedwell <greg_bedwell@sn.scee.net>
Thu, 12 Feb 2015 12:41:28 +0000 (12:41 +0000)
Previously the test did not have a RUN: prefix for the clang command.
In addition it was leaving behind a tmp file with no permissions causing issues when
deleting the build directory on Windows.

Differential Revision: http://reviews.llvm.org/D7534

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

test/Frontend/dependency-generation-crash.c

index 181bb71f1b092258f7e5797336f2f12f90ec71e8..63a6a7732e9b825b5eb91c857006721a2a343a58 100644 (file)
@@ -1,4 +1,8 @@
 // RUN: touch %t
 // RUN: chmod 0 %t
-// %clang -E -dependency-file bla -MT %t -MP -o %t -x c /dev/null
+// RUN: not %clang_cc1 -E -dependency-file bla -MT %t -MP -o %t -x c /dev/null 2>&1 | FileCheck %s
+// RUN: rm -f %t
+
+// CHECK: error: unable to open output file
+
 // rdar://9286457