Added quickcheck tests.