The difference is that in the code you where looking at, they have a typeclass
class PriorityQueue pq where
insert ...
With a bunch of operations for different priority queues. However, you don't have a typeclass. You have a datatype PQ
which is a concrete type representing one implementation of a priority queue, namely a meldable heap.
Try instead
pqArbitrary :: (Arbitrary a, Ord a) => Gen (PQ a)
pqArbitrary = liftM (foldr (\x acc -> insert x acc) empty) (listOf arbitrary)
pqArbitrary' = foldr insert empty `fmap` listOf arbitrary
Also, I have to comment on the irony of testing one of the handful of packages on Hackage that's proven correct :) (meldable-heap is verified with coq)