How to treat testsuite timeout as success?

Merijn Verstraaten merijn at
Sat Nov 1 23:01:35 UTC 2014


I was trying to re-re-fix and add a test-case for this fix. However, I'm having trouble creating a test that can actually be successful. The simplest case exhibiting the issue (on OSX) is that "main = threadDelay maxBound" crashes, I need a way to treat a timeout of say 5-10s as success, since the testsuite won't let my test run for 25,000 days :D

I can't add a timeout inside the haskell code (along the lines of "threadDelay 10000000 >> exitSuccess" since installing any other timers with a timeout shorter than the crashing one masks the crash. Marking the test as expected to fail doesn't help, as this treats both a crash due to the bug and a timeout as success. Clearly only timeout should be considered successful.


PS - For the curious willing to help verify that the third time's the charm:

More information about the ghc-devs mailing list