Hi,
 
On Tue, 5 Mar 2019 at 23:11, Will Yager <will.yager@gmail.com> wrote:
>
> http://hackage.haskell.org/package/dejafu might do what you want

Thanks for the suggestion, that does look useful.
>From a quick look at the documentation... am I right in thinking that
this test framework only covers concurrency when you're directly using
IOVars and STM?  Any concurrency that might involve other primitives,
or IOVar/STM uses in libraries, wouldn't be testable?  Unless the
primitives/library had also been written to use the dejafu io classes
and monads of course... which might be a good idea in and of itself.

Yes, that's the case.  It's a bit of an unfortunate limitation but I don't currently have a way around it.

You may find it interesting to look at adjoint.io's libraft, which uses dejafu for some tests: https://github.com/adjoint-io/raft/blob/master/test/TestDejaFu.hs

The way they do it is by writing their library in terms of some "MonadRaft" classes, and give a concrete implementation of those classes in terms of dejafu's ConcIO monad for testing. 

--