aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests/forkprocess01.hs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/forkprocess01.hs')
-rw-r--r--tests/forkprocess01.hs9
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/forkprocess01.hs b/tests/forkprocess01.hs
new file mode 100644
index 0000000..b4bc78b
--- /dev/null
+++ b/tests/forkprocess01.hs
@@ -0,0 +1,9 @@
+-- Test that we can call exitFailure in a forked process, and have it
+-- communicated properly to the parent.
+import System.Exit
+import System.Posix.Process
+main = do
+ p <- forkProcess exitFailure
+ r <- getProcessStatus True False p
+ print r
+