| Safe Haskell | None |
|---|---|
| Language | GHC2021 |
Futhark.Test.Property
Synopsis
- runPBT :: PBTConfig -> Server -> [PropSpec] -> IORef PBTPhase -> FilePath -> IO [Either PBTFailure PBTOutput]
- data PBTConfig = PBTConfig {}
- data PBTPhase = PBTPhase {}
- data PropSpec = PropSpec {}
- type PBTOutput = Maybe Text
- type PBTFailure = Text
- extractPropSpecs :: Server -> [EntryName] -> IO (Either PBTFailure [PropSpec])
Documentation
runPBT :: PBTConfig -> Server -> [PropSpec] -> IORef PBTPhase -> FilePath -> IO [Either PBTFailure PBTOutput] Source #
Run a list of property specifications, returning a list of results. Each result is either a failure with an error message or a success.
Configuration for property-based testing. Includes parameters for test case generation, shrinking, and random seed management.
Constructors
| PBTConfig | |
Fields
| |
Information about the current phase of property-based testing, used for logging and debugging.
Constructors
| PBTPhase | |
Fields
| |
Specification for a property to be tested, including the property entry point and optional generator and shrinker entry points, as well as an optional size parameter.
Constructors
| PropSpec | |
Fields
| |
type PBTOutput = Maybe Text Source #
Output of a property-based test run, which is either a failure with an error message or a success.
type PBTFailure = Text Source #
Failure in property-based testing, represented as an error message. For example a division by zero runtime error.
extractPropSpecs :: Server -> [EntryName] -> IO (Either PBTFailure [PropSpec]) Source #
Extract property specifications from the server by looking for entry points with #[prop(...)] attributes, comparing with the declared list of properties.