Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- data ScriptEvaluationEvents = ScriptEvaluationEvents {}
- data ScriptEvaluationEvent = PlutusEvent PlutusLedgerLanguage ScriptEvaluationData ScriptEvaluationResult
- data ScriptEvaluationData = ScriptEvaluationData {}
- data ScriptEvaluationResult
- data UnexpectedEvaluationResult
- data TestFailure
- renderTestFailure ∷ TestFailure → String
- renderTestFailures ∷ NonEmpty TestFailure → String
- checkEvaluationEvent ∷ EvaluationContext → [Int64] → ScriptEvaluationEvent → Maybe UnexpectedEvaluationResult
Documentation
data ScriptEvaluationEvents Source #
This type contains a list of on-chain script evaluation events. All PlutusV1 evaluations (if any) share the same cost parameters. Same with PlutusV2.
Sharing the cost parameters lets us avoid creating a new EvaluationContext
for
each ScriptEvaluationEvent
.
ScriptEvaluationEvents | |
|
Instances
Generic ScriptEvaluationEvents Source # | |
Defined in PlutusLedgerApi.Test.EvaluationEvent | |
Serialise ScriptEvaluationEvents Source # | |
type Rep ScriptEvaluationEvents Source # | |
Defined in PlutusLedgerApi.Test.EvaluationEvent type Rep ScriptEvaluationEvents = D1 ('MetaData "ScriptEvaluationEvents" "PlutusLedgerApi.Test.EvaluationEvent" "plutus-ledger-api-1.38.0.0-inplace-plutus-ledger-api-testlib" 'False) (C1 ('MetaCons "ScriptEvaluationEvents" 'PrefixI 'True) (S1 ('MetaSel ('Just "eventsCostParamsV1") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe [Int64])) :*: (S1 ('MetaSel ('Just "eventsCostParamsV2") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe [Int64])) :*: S1 ('MetaSel ('Just "eventsEvents") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (NonEmpty ScriptEvaluationEvent))))) |
data ScriptEvaluationEvent Source #
Information about an on-chain script evaluation event, specifically the information needed to evaluate the script, and the expected result.
Instances
data ScriptEvaluationData Source #
All the data needed to evaluate a script using the ledger API, except for the cost model parameters, as these are tracked separately.
Instances
data ScriptEvaluationResult Source #
Instances
Generic ScriptEvaluationResult Source # | |
Defined in PlutusLedgerApi.Test.EvaluationEvent | |
Show ScriptEvaluationResult Source # | |
Defined in PlutusLedgerApi.Test.EvaluationEvent | |
Pretty ScriptEvaluationResult Source # | |
Defined in PlutusLedgerApi.Test.EvaluationEvent pretty ∷ ScriptEvaluationResult → Doc ann Source # prettyList ∷ [ScriptEvaluationResult] → Doc ann Source # | |
Serialise ScriptEvaluationResult Source # | |
type Rep ScriptEvaluationResult Source # | |
Defined in PlutusLedgerApi.Test.EvaluationEvent type Rep ScriptEvaluationResult = D1 ('MetaData "ScriptEvaluationResult" "PlutusLedgerApi.Test.EvaluationEvent" "plutus-ledger-api-1.38.0.0-inplace-plutus-ledger-api-testlib" 'False) (C1 ('MetaCons "ScriptEvaluationSuccess" 'PrefixI 'False) (U1 ∷ Type → Type) :+: C1 ('MetaCons "ScriptEvaluationFailure" 'PrefixI 'False) (U1 ∷ Type → Type)) |
data UnexpectedEvaluationResult Source #
Error type when re-evaluating a ScriptEvaluationEvent
.
UnexpectedEvaluationSuccess | |
| |
UnexpectedEvaluationFailure | |
| |
DecodeError ScriptDecodeError |
Instances
data TestFailure Source #
∷ EvaluationContext | |
→ [Int64] | Cost parameters |
→ ScriptEvaluationEvent | |
→ Maybe UnexpectedEvaluationResult |
Re-evaluate an on-chain script evaluation event.