identity package:leancheck

Deprecated: Use isIdentity.
Is the given function an identity? f x == x
> check $ isIdentity (+0)
+++ OK, passed 200 tests.
> check $ isIdentity (sort :: [()]->[()])
+++ OK, passed 200 tests.
> check $ isIdentity (not . not)
+++ OK, passed 2 tests (exhausted).
Is the given function never an identity? f x /= x
> check $ neverIdentity not
+++ OK, passed 2 tests (exhausted).
> check $ neverIdentity negate
*** Failed! Falsifiable (after 1 tests):
0
Note: this is not the same as not being an identity.
Deprecated: Use isNeverIdentity.