[Haskell-cafe] QuickCheck, (Ord a)=> [a] -> Property problem

larry.liuxinyu liuxinyu95 at gmail.com
Fri Apr 22 10:28:48 CEST 2011


Hi,

I tested with Haskell platform 2011 with QuickCheck 2.4.0.1.
It produced 100 cases passed, but can't report failed case.
verboseCheck still told me that [(), (), ... ()] are generated as
instance to (Ord a)

The only way is to specify the non-ambitious type for example, Int,
like below:

test (prop_foo::[Int]->Property)

Cheers.
--
Larry.

On Apr 22, 5:56 am, Nick Smallbone <nick.smallb... at gmail.com> wrote:
> "larry.liuxinyu" <liuxiny... at gmail.com> writes:
> > Somebody told me that:
> > Eduard Sergeev • BTW, more recent QuickCheck (from Haskell Platform
> > 2011.2.0.X - contains QuickCheck-2.4.0.1) seems to identifies the
> > problem correctly:
>
> > *** Failed! Falsifiable (after 3 tests and 2 shrinks):
> > [0,1]
> > False
>
> I don't think this can be true: the problem occurs in GHCi and there's
> no way for QuickCheck to detect it. And when I tested it I got the same
> problem. There must be some difference between the properties you both
> tested...
>
> Nick
>
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-C... at haskell.orghttp://www.haskell.org/mailman/listinfo/haskell-cafe



More information about the Haskell-Cafe mailing list