summaryrefslogtreecommitdiffstats
path: root/Tests/CTestTestZeroTimeout/sleep.c
diff options
context:
space:
mode:
authorZach Mullen <zach.mullen@kitware.com>2011-01-03 19:41:25 (GMT)
committerZach Mullen <zach.mullen@kitware.com>2011-01-03 19:41:25 (GMT)
commit51bb49357495ea2742858ffe9d76ab3f44efc06e (patch)
treef72a5b8ce58fc95f46d2b477196ded88e642cda8 /Tests/CTestTestZeroTimeout/sleep.c
parentedff9207ed82d241077d66b20087657f74e8b5b9 (diff)
downloadCMake-51bb49357495ea2742858ffe9d76ab3f44efc06e.zip
CMake-51bb49357495ea2742858ffe9d76ab3f44efc06e.tar.gz
CMake-51bb49357495ea2742858ffe9d76ab3f44efc06e.tar.bz2
Test TIMEOUT property explicitly set to zero should be honored
Diffstat (limited to 'Tests/CTestTestZeroTimeout/sleep.c')
-rw-r--r--Tests/CTestTestZeroTimeout/sleep.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/Tests/CTestTestZeroTimeout/sleep.c b/Tests/CTestTestZeroTimeout/sleep.c
new file mode 100644
index 0000000..d40d59d
--- /dev/null
+++ b/Tests/CTestTestZeroTimeout/sleep.c
@@ -0,0 +1,16 @@
+#if defined(_WIN32)
+# include <windows.h>
+#else
+# include <unistd.h>
+#endif
+
+/* sleeps for 5 seconds */
+int main(int argc, char** argv)
+{
+#if defined(_WIN32)
+ Sleep(5000);
+#else
+ sleep(5);
+#endif
+ return 0;
+}