The order of the returned values weren't deterministic so switched to shouldMatchList

This commit is contained in:
Fintan Halpenny 2017-08-04 15:16:31 +01:00
parent 406c1ef46c
commit 2f5715470d

View File

@ -1158,9 +1158,8 @@ main = do
on $ lord ^. LordId ==. deed ^. DeedOwnerId
groupBy (lord ^. LordId)
return (lord ^. LordId, count $ deed ^. DeedId)
liftIO $ ret `shouldBe` [ (Value l3k, Value 7)
, (Value l1k, Value 3) ]
liftIO $ ret `shouldMatchList` [ (Value l3k, Value 7)
, (Value l1k, Value 3) ]
it "GROUP BY works with HAVING" $
run $ do
p1k <- insert p1