API reference
Generated by reflection (docs/scripts/reflect-api.php) over all three packages' src/, not written by hand — every signature, parameter and default value here is read straight from the code, not transcribed from it. Only @api-annotated types get a page; @internal classes are implementation detail and stay undocumented on purpose.
Core
| Type | Kind | Summary |
|---|---|---|
ArrayArbitrary | class | Generates lists whose elements come from a delegate arbitrary and shrinks them by length toward… |
BoolArbitrary | class | Generates booleans. |
BytesArbitrary | class | Generates raw byte strings (every byte 0..255, not printable text) and shrinks them by length… |
CharsetStringArbitrary | class | Generates strings whose characters come from a fixed alphabet, and shrinks them by length toward… |
ClassArbitrary | class | Instances of a class, generated from what its constructor already declares. |
CommandSequenceArbitrary | class | Generates valid Command sequences for stateful / model-based testing and shrinks them by dropping… |
CompositeArbitrary | class | A value built by a body that draws several dependent values through a Draw, shrinking the draws… |
ConstantArbitrary | class | Always produces the same fixed value. |
DateTimeArbitrary | class | Generates UTC DateTimeImmutable values with microsecond precision, drawn uniformly from an… |
DictionaryArbitrary | class | Generates associative arrays (maps) whose keys come from a key arbitrary and whose values come… |
DrawnEngine | class | A Random\Engine whose output is drawn from the property's own replay tape: every generate() is… |
EdgeCasedArbitrary | class | A delegate arbitrary with author-supplied boundary values: one draw in self::BIAS_DENOMINATOR is… |
FilteredArbitrary | class | Generates values from a delegate arbitrary, retrying until a predicate holds. |
FlatMappedArbitrary | class | Dependent generators (monadic bind): each value produced by the source arbitrary is fed into a… |
FloatArbitrary | class | Generates floats in the half-open range [min, max). |
FrequencyArbitrary | class | Weighted choice among several arbitraries: each [weight, arbitrary] pair is picked with… |
IntArbitrary | class | Generates integers within an inclusive range and shrinks them toward zero (clamped into the range,… |
MappedArbitrary | class | Transforms each value produced by a delegate arbitrary through a pure function. |
NullableArbitrary | class | Wraps another arbitrary and additionally yields null with roughly even odds. |
OneOfArbitrary | class | Picks a value uniformly at random from a fixed set. |
RandomEngineArbitrary | class | Yields a DrawnEngine. |
RecordArbitrary | class | Fixed-shape associative array: produces a map with one value per named field, each drawn from that… |
StringArbitrary | class | Generates random strings and shrinks them by length toward the empty string, then… |
SubsetArbitrary | class | Generates subsets of a fixed ordered set: every result is a list of distinct elements of the… |
SwarmArbitrary | class | Swarm testing over a choice generator: every generated case may only use some of the variants,… |
TupleArbitrary | class | Fixed-arity tuple: produces a list with one value per element arbitrary, in order. |
UniqueArrayArbitrary | class | Generates lists of pairwise-distinct elements drawn from a delegate arbitrary, and shrinks them by… |
UuidArbitrary | class | Generates RFC 4122 version 4 (random) UUID strings in the canonical… |
ArbitraryInterface | interface | Describes a space of random values with integrated shrinking. |
Assume | class | Discard a property run when a precondition does not hold. |
AssumptionSkipped | class | Thrown by Assume::that() to discard the current property run without counting it as a failure or a… |
Classify | class | Records distribution labels for the current property run so the runner can report how often each… |
CounterExample | class | Minimal failing input for a property, captured at falsification time. |
CoverageViolationException | class | Thrown (as the failure of an otherwise passing property) when a coverage requirement registered… |
DeadlineExceededException | class | Thrown (as the failure of a property) when a single run's body takes longer than the… |
Draw | class | The draw seam a Gen::composite() body receives: every value the body needs comes through draw(),… |
Enumerable | interface | A generator whose whole domain can be counted and walked — the seam the exhaustive mode of… |
CorpusFailed | class | The corpus threw — a Redis server that refused the connection, a database that could not be… |
CorpusPruned | class | A recorded entry no longer fails and was removed from the corpus. |
CorpusReplayed | class | A recorded regression entry is about to replay before the random phase. |
CorpusStored | class | A falsification's minimised counterexample was recorded in the corpus. |
ExampleFinished | class | An explicit example finished. |
ExampleStarted | class | An explicit example is about to execute, before the random phase. |
PropertyEvent | interface | Marker for the engine's lifecycle events. |
PropertyFinished | class | The property finished. |
PropertyStarted | class | The property is about to run: examples first, then corpus replay, then the random phase. |
RunDiscarded | class | A random-phase attempt was discarded — neither a failure nor a successful check. |
RunFailed | class | A random-phase attempt falsified the property; shrinking follows. |
RunPassed | class | A random-phase attempt completed without failing. |
RunStarted | class | A random-phase attempt is about to execute the property body. |
ShrinkAccepted | class | A shrink candidate still failed and became the new current counterexample. |
ShrinkTried | class | One shrink trial executed the body with a smaller candidate for a single parameter (or draw#N… |
TargetImproved | class | A passing run scored better on a Target label than any before it — in… |
ExampleViolationException | class | Reported when an explicit example (a fixed input declared via the property's Examples method)… |
GaveUpException | class | Thrown (as the failure of a property) when discarded inputs — or runs the environment refused —… |
Gen | class | Facade with static factories for the built-in ArbitraryInterfaces. |
GenerationExhaustedException | class | Thrown when a bounded-attempt generator cannot produce a value that satisfies its constraint… |
PathViolationException | class | Reported when a run pinned to a shrink path cannot follow it: the candidate a step names is gone,… |
PropertyId | class | What a property's id has to be good for, and how to tell when it is not. |
PropertyListener | interface | Observer of a property run's lifecycle events. |
PropertyTestingException | interface | Marker for every exception this engine reports, so a caller can catch the package as a whole… |
PropertyViolationException | class | Reported when a property is falsified. |
Random | class | Seedable, deterministic pseudo-random number generator. |
RegressionViolationException | class | Reported when a recorded regression fails again: the minimised input of an earlier failure,… |
CallableTrialExecutor | class | The standalone executor: a plain callback is the property body. |
Clock | interface | Monotonic time source behind the per-run deadline and the phase budget. |
Corpus | interface | Persistent store of past falsifications, replayed before the random phase. |
CorpusEntry | class | One recorded regression in a property's corpus: either the minimised failing input itself (a… |
CorpusFactory | class | The corpus a PROPERTY_DB value names. |
CoverageFailed | class | Every run passed, but a Classify::cover() requirement was under-covered — the pass is… |
DeadlineExceeded | class | A single run (random, example or regression replay) took longer than the per-run deadline. |
DistributionReport | class | What the random phase actually generated, as data: every Classify label… |
EdgeCases | enum | Whether the numeric generators keep biasing toward their boundary values. |
EnvironmentOverrides | class | The values of the PROPERTY_* environment variables, parsed. |
ExampleFailed | class | An explicit example failed before the random phase. |
Falsified | class | A random run falsified the property; the counterexample is shrunk. |
FilesystemCorpus | class | Opt-in on-disk corpus of a property's past failures, replayed before the random phase so a fixed… |
GaveUp | class | Discarded inputs — or runs the environment refused — exceeded their budget before the requested… |
GenerationFailed | class | A generator could not produce a valid value (e.g. |
LabelShare | class | How often one Classify label occurred, together with the… |
MonotonicClock | class | The default Clock: hrtime(), monotonic and immune to a wall-clock adjustment mid-run. |
Passed | class | Every check completed and every coverage requirement held. |
PathFailed | class | A run pinned to a shrink path found its falsification but could not follow the recorded descent. |
Phase | enum | The stages of one property run, as an explicit set rather than a fixed sequence. |
PropertyConfig | class | Resolved knobs of one property run. |
PropertyDefinition | class | One property, fully resolved for the engine: no attribute, no reflection, no environment. |
PropertyResult | interface | Structured outcome of a property run. |
PropertyRunner | class | The framework-agnostic property engine: runs the explicit examples, replays the regression corpus,… |
CorpusClient | interface | The two operations Runner\RedisCorpus needs from a Redis client, and… |
LazyPhpRedisCorpusClient | class | A PhpRedisCorpusClient that connects on first use. |
PhpRedisCorpusClient | class | CorpusClient over the ext-redis client (\Redis). |
PredisCorpusClient | class | CorpusClient over predis. |
RedisDsn | class | redis://host[:port][/db][?prefix=key-prefix&timeout=seconds] (or rediss:// for TLS), taken apart. |
RedisCorpus | class | A Corpus in Redis, so one falsification is replayed everywhere. |
RegressionFailed | class | A recorded regression (a values corpus entry) failed again on replay. |
RunStatistics | class | Counters of a random phase, carried by the results whose reporting needs them: the classification… |
SearchCorpus | interface | The adaptive example database behind targeted search: the best-scoring inputs of every… |
SearchReport | class | What the targeted search of a run amounted to, as data: how many bodies the search phase executed… |
ShrinkMode | enum | How hard the runner works to minimise a counterexample. |
TargetDirection | enum | Which way a Target label is pushed. |
TargetOutcome | class | What the search did for one Target label. |
TimeBudgetExceeded | class | The whole random phase overran its wall-clock budget before the requested checks completed. |
TrialExecutor | interface | Executes the property body once with the given arguments. |
TrialOutcome | class | Result of executing the property body once, in the engine's terms. |
Shrinkable | class | A generated value together with a lazy tree of progressively "smaller" variants of it — the unit… |
Command | interface | A single operation in a stateful / model-based test. |
CommandSequence | class | A generated, valid-by-construction sequence of Commands together with the initial model it was… |
Invariant | class | Marks a public method of a rule-based machine as an invariant: it runs before the first step and… |
PostconditionViolationException | class | Thrown by StateMachine::check() when a command's Command::postCondition() returns false. |
Precondition | class | Names the guard of a Rule: a public method of the machine returning bool, evaluated against the… |
Rule | class | Marks a public method of a rule-based machine as one step the generated sequence may take. |
RuleSequence | class | A generated sequence of RuleSteps over a rule-based machine — what… |
RuleStep | class | One step of a rule-based sequence: a Rule method and the arguments drawn for it. |
StateMachine | class | Drives a CommandSequence against a fresh system under test for stateful / model-based testing. |
Swarmable | interface | A generator that picks among a fixed, countable set of variants and can hand back a copy of itself… |
Target | class | Reports a score the engine should push toward an extreme: a delay, a recursion depth, a queue… |
TimeBudgetExceededException | class | Thrown (as the failure of a property) when the random phase's wall-clock time exceeds the… |
ValueRenderer | class | Renders an arbitrary value into a compact, human-readable string for counterexample reporting. |
Testo adapter
| Type | Kind | Summary |
|---|---|---|
Property | class | Marks a test method as a property: the PropertyInterceptor takes over, generating random arguments… |
PropertyInterceptor | class | The Testo adapter for a Property: resolves the test framework's conventions — the attribute, the… |
PHPUnit adapter
| Type | Kind | Summary |
|---|---|---|
PropertyCheck | class | Fluent builder mapping the engine's structured PropertyResult onto PHPUnit: a pass counts one… |
PropertyTesting | trait | The fluent entry point a PHPUnit TestCase mixes in: |