genvalidity-property-1.0.0.0: Standard properties for functions on `Validity` types

Safe Haskell | None
Language | Haskell2010

Test.Validity.Relations.Transitivity

Synopsis

- transitiveOnElems :: (a -> a -> Bool) -> a -> a -> a -> Bool
- transitivityOnGens :: Show a => (a -> a -> Bool) -> Gen (a, a, a) -> (a -> [a]) -> Property
- transitivity :: (Show a, GenValid a) => (a -> a -> Bool) -> Property
- transitivityOnArbitrary :: (Show a, Arbitrary a) => (a -> a -> Bool) -> Property

# Documentation

transitiveOnElems Source #

Arguments

:: (a -> a -> Bool) | A relation
-> a |
-> a |
-> a | Three elements
-> Bool |

\[ Transitive(\prec) \quad\equiv\quad \forall a, b, c: ((a \prec b) \wedge (b \prec c)) \Rightarrow (a \prec c) \]

transitivityOnGens :: Show a => (a -> a -> Bool) -> Gen (a, a, a) -> (a -> [a]) -> Property Source #

transitivity :: (Show a, GenValid a) => (a -> a -> Bool) -> Property Source #

    transitivity ((>) :: Int -> Int -> Bool)

    transitivity ((>=) :: Int -> Int -> Bool)

    transitivity ((==) :: Int -> Int -> Bool)

    transitivity ((<=) :: Int -> Int -> Bool)

    transitivity ((<) :: Int -> Int -> Bool)

    transitivity (Data.List.isPrefixOf :: [Int] -> [Int] -> Bool)

    transitivity (Data.List.isSuffixOf :: [Int] -> [Int] -> Bool)

    transitivity (Data.List.isInfixOf :: [Int] -> [Int] -> Bool)

transitivityOnArbitrary :: (Show a, Arbitrary a) => (a -> a -> Bool) -> Property Source #

    transitivityOnArbitrary ((>) :: Int -> Int -> Bool)

    transitivityOnArbitrary ((>=) :: Int -> Int -> Bool)

    transitivityOnArbitrary ((==) :: Int -> Int -> Bool)

    transitivityOnArbitrary ((<=) :: Int -> Int -> Bool)

    transitivityOnArbitrary ((<) :: Int -> Int -> Bool)

    transitivityOnArbitrary (Data.List.isPrefixOf :: [Int] -> [Int] -> Bool)

    transitivityOnArbitrary (Data.List.isSuffixOf :: [Int] -> [Int] -> Bool)

    transitivityOnArbitrary (Data.List.isInfixOf :: [Int] -> [Int] -> Bool)