HORIZON HASKELLDocslts/ghc-10.0.x77a86622026-10-31Search packagesCtrl K
Theme: |

GHC 10.0.0.20260917 · lts/ghc-10.0.x · 77a8662 · 2026-10-31

Modulegenvalidity-property-1.0.0.0Haskell2010

Test.Validity.Functions.Idempotence

Standard tests involving validity

Synopsis
valueidempotentOnArbitrary :: (Show a, Eq a, Arbitrary a) => (a -> a) -> Property

id is idempotent for any type:

Property
idempotentOnArbitrary (id :: Int -> Int)

const, given any input, is idempotent for any type as well:

Property
\int -> idempotentOnArbitrary (const int :: Int -> Int)