Fix test to use %t for newly created files.
authorTim Shen <timshen91@gmail.com>
Fri, 13 Sep 2019 21:06:47 +0000 (21:06 +0000)
committerTim Shen <timshen91@gmail.com>
Fri, 13 Sep 2019 21:06:47 +0000 (21:06 +0000)
This is both for consistency with other `mkdir`s in tests, and
fixing permission issues with the non-temporary cwd during testing (they
are not always writable).

llvm-svn: 371897

clang/test/Driver/metadata-with-dots.c

index 371b48b..6058b91 100644 (file)
@@ -1,10 +1,10 @@
 // REQUIRES: shell
-// RUN: mkdir -p out.dir
-// RUN: cat %s > out.dir/test.c
-// RUN: %clang -E -MMD %s -o out.dir/test
+// RUN: mkdir -p %t/out.dir
+// RUN: cat %s > %t/out.dir/test.c
+// RUN: %clang -E -MMD %s -o %t/out.dir/test
 // RUN: test ! -f %out.d
-// RUN: test -f out.dir/test.d
-// RUN: rm -rf out.dir/test.d out.dir/ out.d
+// RUN: test -f %t/out.dir/test.d
+// RUN: rm -rf %t/out.dir/test.d %t/out.dir/ out.d
 int main (void)
 {
     return 0;