Skip to content

Commit

Permalink
Use arbitraryBoundedEnum to avoid repeating the definition of `Sort…
Browse files Browse the repository at this point in the history
…Order`.
  • Loading branch information
jonathanknowles committed Aug 1, 2019
1 parent 4f00014 commit a99a8c9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/core/test/unit/Cardano/Wallet/DB/StateMachine.hs
Expand Up @@ -107,6 +107,7 @@ import Test.QuickCheck
, Args (..)
, Gen
, Property
, arbitraryBoundedEnum
, collect
, elements
, frequency
Expand Down Expand Up @@ -538,7 +539,7 @@ generator (Model _ wids) = Just $ frequency $ fmap (fmap At) <$> concat
genPrivKey = elements ["pk1", "pk2", "pk3"]

genSortOrder :: Gen SortOrder
genSortOrder = QC.elements [Ascending, Descending]
genSortOrder = arbitraryBoundedEnum

genRange :: Gen (Range SlotId)
genRange = Range <$> genSId <*> genSId
Expand Down

0 comments on commit a99a8c9

Please sign in to comment.