@hegeldev/hegel
    Preparing search index...

    Interface StateMachine<S>

    A state machine over states of type S: named rules and (optionally) named invariants. The names appear in the failure report (Step 3: pop, Invariant nonNegativeLength failed after step 3:).

    A machine object holds no state of its own, so one machine can be run against a fresh initial state in every test case.

    interface StateMachine<S> {
        invariants?: Record<string, Invariant<S>>;
        rules: Record<string, Rule<S>>;
    }

    Type Parameters

    • S
    Index

    Properties

    Properties

    invariants?: Record<string, Invariant<S>>
    rules: Record<string, Rule<S>>