aeyakovenko:
> If i have functions in the IO monad, is there a way to use quickcheck
> to test them? I have a bunch of C bindings that unfortunately are not
> "safe". But i would like to be able to use QuickCheck to test them.
>
Typically, via unsafePerformIO, and check the invariants that need to
hold for that to be safe by hand.
E.g.
prop_foo x = unsafePerformIO $ do
writeFile "f" x
y <- readFile "f"
return (x == y)
-- Don
_______________________________________________
Haskell-Cafe mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe