[cfe-commits] r168082 - /cfe/trunk/test/Misc/dev-fd-fs.c
Daniel Dunbar
daniel at zuster.org
Thu Nov 15 12:24:58 PST 2012
Author: ddunbar
Date: Thu Nov 15 14:24:58 2012
New Revision: 168082
URL: http://llvm.org/viewvc/llvm-project?rev=168082&view=rev
Log:
tests: Check that we can output to /dev/fd filesystem.
- An LLVM unique_file() bug could cause us to infinite loop on the later test
case.
Modified:
cfe/trunk/test/Misc/dev-fd-fs.c
Modified: cfe/trunk/test/Misc/dev-fd-fs.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Misc/dev-fd-fs.c?rev=168082&r1=168081&r2=168082&view=diff
==============================================================================
--- cfe/trunk/test/Misc/dev-fd-fs.c (original)
+++ cfe/trunk/test/Misc/dev-fd-fs.c Thu Nov 15 14:24:58 2012
@@ -7,6 +7,24 @@
//
// RUN: cat %s | %clang -x c /dev/fd/0 -E > %t
// RUN: FileCheck --check-prefix DEV-FD-INPUT < %t %s
-
+//
// DEV-FD-INPUT: int x;
+
+
+// Check writing to /dev/fd named pipes. We use cat here as before to ensure we
+// get a named pipe.
+//
+// RUN: %clang -x c %s -E -o /dev/fd/1 | cat > %t
+// RUN: FileCheck --check-prefix DEV-FD-FIFO-OUTPUT < %t %s
+//
+// DEV-FD-FIFO-OUTPUT: int x;
+
+
+// Check writing to /dev/fd regular files.
+//
+// RUN: %clang -x c %s -E -o /dev/fd/1 > %t
+// RUN: FileCheck --check-prefix DEV-FD-REG-OUTPUT < %t %s
+//
+// DEV-FD-REG-OUTPUT: int x;
+
int x;
More information about the cfe-commits
mailing list