Interface IGeneratorContext
- Namespace
- Conjecture.Core
- Assembly
- Conjecture.Core.dll
Provides imperative draw and assume operations within a Generate.Compose factory.
public interface IGeneratorContext
Methods
Assume(bool)
Rejects the current test case if condition is false.
void Assume(bool condition)
Parameters
conditionbool
Generate<T>(Strategy<T>)
Generates a value from strategy.
T Generate<T>(Strategy<T> strategy)
Parameters
strategyStrategy<T>
Returns
- T
Type Parameters
T
Target(double, string)
Records a numeric observation to guide targeted generation.
void Target(double observation, string label = "default")