diff options
Diffstat (limited to 'test/Crypto/Macaroon')
-rw-r--r-- | test/Crypto/Macaroon/Instances.hs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/Crypto/Macaroon/Instances.hs b/test/Crypto/Macaroon/Instances.hs index 5d4b062..4e2f39f 100644 --- a/test/Crypto/Macaroon/Instances.hs +++ b/test/Crypto/Macaroon/Instances.hs | |||
@@ -23,6 +23,12 @@ import Test.Tasty.QuickCheck | |||
23 | 23 | ||
24 | import Crypto.Macaroon | 24 | import Crypto.Macaroon |
25 | 25 | ||
26 | |||
27 | -- | Adjust the size parameter, by transforming it with the given | ||
28 | -- function. | ||
29 | scale :: (Int -> Int) -> Gen a -> Gen a | ||
30 | scale f g = sized (\n -> resize (f n) g) | ||
31 | |||
26 | newtype Url = Url { unUrl :: BS.ByteString } deriving (Show) | 32 | newtype Url = Url { unUrl :: BS.ByteString } deriving (Show) |
27 | 33 | ||
28 | instance Arbitrary Url where | 34 | instance Arbitrary Url where |