================
@@ -0,0 +1,14 @@
+// RUN: rm -rf %t
+// RUN: mkdir %t
+// RUN: echo "" > %t/compile_flags.txt
+// RUN: cp "%s" "%t/test.cpp"
+// RUN: clang-doc --format=html --executor=standalone -p %t %t/test.cpp 
-output=%t/docs > %t/output.txt
+// RUN: cat %t/output.txt | FileCheck %s --check-prefix=CHECK
----------------
ilovepi wrote:

```suggestion
// RUN: clang-doc --format=html --executor=standalone -p %t %s -output=%t/docs 
2>&1 | FileCheck %s 
```
1. No point in making an empty file. If it was necessary, `touch` would have 
been more appropriate. (BTW, what is compile_flags.txt?)
1.  you can just reference this test file, just as well, without copying it at 
all. If there's some reason it has to be that way, write it down in comments.
1. no need for `output.txt`, just pipe it straight into `FileCheck`. If you 
need the file later, you still don't need to `cat`, you can just pass the file 
to `FileCheck`
2. You don't need to list `CHECK` under `--check-prefix=`. It's the default.

https://github.com/llvm/llvm-project/pull/94717
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to