You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I played with the buildTestBracketed feature today and got the impression,
that the cleanup happens too early.
My guess is, that cleanup should only be called after taking all mvars:
diff --git a/core/Test/Framework/Runners/Core.hs b/core/Test/Framework/Runners/Core.hs
index 6e15b0a..42db5b7 100644
--- a/core/Test/Framework/Runners/Core.hs
+++ b/core/Test/Framework/Runners/Core.hs
@@ -105,7 +105,7 @@ instance TestRunner StdRunner where
--
-- FIXME: this is a bit of a hack because it uses one pool thread just waiting
-- for some other pool threads to complete! Switch to parallel-io?
- return $ Just (run_test, actions' ++ [(cleanup >> mapM_ takeMVar mvars)])
+ return $ Just (run_test, actions' ++ [(mapM_ takeMVar mvars >> cleanup)])
runTests' :: [StdRunner] -> IO ([RunningTest], [IO ()])
runTests' = fmap (onRight concat . unzip . catMaybes) . mapM run
The text was updated successfully, but these errors were encountered:
I played with the buildTestBracketed feature today and got the impression,
that the cleanup happens too early.
My guess is, that cleanup should only be called after taking all mvars:
The text was updated successfully, but these errors were encountered: