Serge Le Huitouze <serge.lehuito...@gmail.com> writes: > So, do you have any "methodology" for such use cases?
QuickCheck has the ==> operator, which lets you add a precondition. So you could limit the testing of your property to values that satisfy the precondition. An alternative is to use newtype with a custom generator to produce only data that makes sense. Of course, ideally you should design your types so that all possible values are meaningful :-) -k -- If I haven't seen further, it is by standing in the footprints of giants _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe