From 620920180c625b5a8e12737de4013b18d1fe7f6a Mon Sep 17 00:00:00 2001 From: Neil Mitchell Date: Sat, 14 Oct 2017 23:17:41 +0100 Subject: [PATCH] #538, add a test case --- src/Test/Command.hs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/Test/Command.hs b/src/Test/Command.hs index d6a628518..c27b07672 100755 --- a/src/Test/Command.hs +++ b/src/Test/Command.hs @@ -87,6 +87,14 @@ main = shakeTest_ test $ do when (exit == ExitSuccess) $ error "== ExitSuccess" when (t < 2 || t > 8) $ error $ "failed to timeout, took " ++ show t + -- #538, a bug, but disabled as #538 is broken + when False $ "timeout2" !> do + offset <- liftIO offsetTime + liftIO $ timeout 2 $ cmd_ helper "w20" + t <- liftIO offset + putNormal $ "Timed out in " ++ showDuration t + when (t < 2 || t > 8) $ error $ "failed to timeout, took " ++ show t + "env" !> do -- use liftIO since it blows away PATH which makes lint-tracker stop working Stdout out <- liftIO $ cmd (Env [("FOO","HELLO SHAKE")]) Shell helper "vFOO"