| Safe Haskell | Safe-Inferred |
|---|---|
| Language | Haskell2010 |
Test.Mutagen.Mutant
Description
Abstract test case mutants and their concretization.
Synopsis
- data Mutant a
- data MutantKind
- data Concretized a = Concretized MutantKind a
- concretize :: Typeable a => (Int, Int) -> (Int, FragmentStore) -> Mutant a -> IO [Concretized a]
- data Gen a
- data FragmentStore
Abstract mutants
Mutants representing possibly unrealized mutations over values of type a.
Constructors
| Pure a | A pure mutation obtained after applying a deterministic transformation |
| Rand (Gen a) | A random mutation obtained by sampling from a generator |
| Frag (FragmentStore -> Gen [a]) | A fragment-based mutation obtained by sampling from a fragment store |
data MutantKind Source #
Kinds of concretized mutants.
Constructors
| PureMutant | |
| RandMutant | |
| FragMutant |
Instances
| Show MutantKind Source # | |
Defined in Test.Mutagen.Mutant Methods showsPrec :: Int -> MutantKind -> ShowS # show :: MutantKind -> String # showList :: [MutantKind] -> ShowS # | |
Concretized test cases
data Concretized a Source #
Values obtained by concretizing a mutant.
Constructors
| Concretized MutantKind a |
Instances
| Show a => Show (Concretized a) Source # | |
Defined in Test.Mutagen.Mutant Methods showsPrec :: Int -> Concretized a -> ShowS # show :: Concretized a -> String # showList :: [Concretized a] -> ShowS # | |
Arguments
| :: Typeable a | |
| => (Int, Int) | Count and max generation size for random mutants |
| -> (Int, FragmentStore) | Count and fragment store for fragment mutants |
| -> Mutant a | Mutant to concretize |
| -> IO [Concretized a] |
Turn an abstract mutant into a concrete set of values.
Re-exports
A generator for values of type a.
The third-party packages
QuickCheck-GenT
and
quickcheck-transformer
provide monad transformer versions of Gen.
data FragmentStore Source #
A collection of fragments indexed by their type representation.
Instances
| Monoid FragmentStore Source # | |
Defined in Test.Mutagen.Fragment.Store Methods mempty :: FragmentStore # mappend :: FragmentStore -> FragmentStore -> FragmentStore # mconcat :: [FragmentStore] -> FragmentStore # | |
| Semigroup FragmentStore Source # | |
Defined in Test.Mutagen.Fragment.Store Methods (<>) :: FragmentStore -> FragmentStore -> FragmentStore # sconcat :: NonEmpty FragmentStore -> FragmentStore # stimes :: Integral b => b -> FragmentStore -> FragmentStore # | |