File: MVector.hs

package info (click to toggle)
haskell-hedgehog-classes 0.2.5.4-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 508 kB
  • sloc: haskell: 6,010; makefile: 8
file content (25 lines) | stat: -rw-r--r-- 534 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
{-# LANGUAGE CPP #-}

#if !HAVE_VECTOR

module Spec.MVector (testMUVector) where

testMUVector :: [a]
testMUVector = []

#else

module Spec.MVector (testMUVector) where

import qualified Hedgehog.Gen as Gen
import qualified Hedgehog.Range as Range

import Hedgehog.Classes (Laws, muvectorLaws)

testMUVector :: [(String, [Laws])]
testMUVector =
  [ ("Word8",  [muvectorLaws (Gen.word8  Range.constantBounded)])
  , ("(Int, Word)", [muvectorLaws ((,) <$> Gen.int Range.constantBounded <*> Gen.word Range.constantBounded)])
  ]

#endif