TxVariations

scalus.testing.TxVariations
See theTxVariations companion object
trait TxVariations[S]

Transaction variations generator for property-based and exhaustive testing.

TxVariations generates multiple transaction variations from a given contract state and base template. Each variation represents a different way to construct a transaction (e.g., different input selection, datum values, redeemer arguments).

The TxTemplate provides the sponsor (who pays fees) and signer, while variations build the transaction body.

Type parameters

S

the contract state type, typically extracted from blockchain UTxOs

Attributes

Companion
object
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes

Members list

Value members

Abstract methods

def enumerate(reader: BlockchainReader, state: S, txTemplate: TxTemplate)(using ExecutionContext): Future[Seq[Transaction]]

Generate all transaction variations for the given state.

Generate all transaction variations for the given state.

Returns completed, signed transactions ready to submit.

Value parameters

reader

blockchain reader for UTxO queries and tx completion

state

contract state extracted from blockchain

template

base template providing sponsor and signer

Attributes

Returns

future containing all transaction variations

Concrete methods

def ++(other: TxVariations[S]): TxVariations[S]

Combine two variation generators.

Combine two variation generators.

The resulting generator produces variations from both sources.

Attributes