summaryrefslogtreecommitdiff
path: root/testsuite/tests/lib/libposix/posix006.hs
diff options
context:
space:
mode:
Diffstat (limited to 'testsuite/tests/lib/libposix/posix006.hs')
-rw-r--r--testsuite/tests/lib/libposix/posix006.hs14
1 files changed, 14 insertions, 0 deletions
diff --git a/testsuite/tests/lib/libposix/posix006.hs b/testsuite/tests/lib/libposix/posix006.hs
new file mode 100644
index 0000000000..eb6451dd73
--- /dev/null
+++ b/testsuite/tests/lib/libposix/posix006.hs
@@ -0,0 +1,14 @@
+import Posix
+
+main =
+ epochTime >>= \ start ->
+ sleep 5 >>
+ let timeleft = 0 in
+ epochTime >>= \ finish ->
+ putStr "Started: " >>
+ print start >>
+ putStr "\nSlept: " >>
+ print (5 - timeleft) >>
+ putStr "\nFinished: " >>
+ print finish >>
+ putChar '\n'