TestUtil

scalus.testing.kit.TestUtil
object TestUtil extends ScalusTest

Attributes

Graph
Supertypes
trait ScalusTest
class Object
trait Matchable
class Any
Show all
Self type
TestUtil.type

Members list

Value members

Concrete methods

def createTestAddress(keyHash: String): ShelleyAddress
def findUtxoByAddressAndDatum(tx: Transaction, address: Address, datum: Option[DatumOption] = ...): Option[(TransactionInput, TransactionOutput)]
def getScriptContextV3(tx: Transaction, utxos: Utxos, input: TransactionInput, redeemerTag: RedeemerTag = ..., environment: CardanoInfo = ...): ScriptContext

Deprecated methods

def createTestWallet(address: Address, ada: BigInt): Wallet

Attributes

Deprecated
[Since version 0.13.0] Will be removed
def runValidator(validatorProgram: Program, tx: Transaction, utxo: Utxos, wallet: Wallet, scriptInput: TransactionInput, redeemerTag: RedeemerTag = ..., environment: CardanoInfo = ...): Result

Attributes

Deprecated
[Since version 0.13.0] Will be removed

Inherited methods

Attributes

Inherited from:
ArbitraryInstances
def compareBudgetWithReferenceValue(testName: String, scalusBudget: ExUnits, refBudget: ExUnits, isPrintComparison: Boolean = ...): Unit

Attributes

Inherited from:
ScalusTest
def genAmount: Gen[BigInt]

Attributes

Inherited from:
ArbitraryInstances
def genAsset: Gen[Value]

Attributes

Inherited from:
ArbitraryInstances

Generates a random asset name, which is a ByteString of length between 1 and 32 bytes.

Generates a random asset name, which is a ByteString of length between 1 and 32 bytes.

Attributes

Inherited from:
ArbitraryInstances
def genByteStringOfN(n: Int): Gen[ByteString]

Attributes

Inherited from:
ArbitraryInstances
def genLovelace: Gen[Value]

Attributes

Inherited from:
ArbitraryInstances

Attributes

Inherited from:
ArbitraryInstances
def genToken: Gen[(ByteString, BigInt)]

Attributes

Inherited from:
ArbitraryInstances

Givens

Inherited givens

given TermShrink: Shrink[Term]

Attributes

Inherited from:
ArbitraryInstances
given TxIdV1: Arbitrary[TxId]

Attributes

Inherited from:
ArbitraryInstances
given arbAssocMap[A : Eq, B : Arbitrary]: Arbitrary[AssocMap[A, B]]

Attributes

Inherited from:
ArbitraryInstances
given arbData: Arbitrary[Data]

Attributes

Inherited from:
ArbitraryInstances
given arbList[A : Arbitrary]: Arbitrary[List[A]]

Attributes

Inherited from:
ArbitraryInstances
given arbOption[A : Arbitrary]: Arbitrary[Option[A]]

Attributes

Inherited from:
ArbitraryInstances
given arbSortedMap[A : Ord, B : Arbitrary]: Arbitrary[SortedMap[A, B]]

Attributes

Inherited from:
ArbitraryInstances
given arbitraryConstant: Arbitrary[Constant]

Attributes

Inherited from:
ArbitraryInstances
given arbitraryDefaultUni: Arbitrary[DefaultUni]

Attributes

Inherited from:
ArbitraryInstances
given arbitraryTerm: Arbitrary[Term]

Attributes

Inherited from:
ArbitraryInstances
given bArb: Arbitrary[B]

Attributes

Inherited from:
ArbitraryInstances
given byteStringArb: Arbitrary[ByteString]

Attributes

Inherited from:
ArbitraryInstances
given given_Arbitrary_Address: Arbitrary[Address]

Attributes

Inherited from:
ArbitraryInstances

Attributes

Inherited from:
ArbitraryInstances

Attributes

Inherited from:
ArbitraryInstances

Attributes

Inherited from:
ArbitraryInstances

Attributes

Inherited from:
ArbitraryInstances

Attributes

Inherited from:
ArbitraryInstances
given given_Arbitrary_Program: Arbitrary[Program]

Attributes

Inherited from:
ArbitraryInstances

Attributes

Inherited from:
ArbitraryInstances

Attributes

Inherited from:
ArbitraryInstances

Attributes

Inherited from:
ArbitraryInstances
given given_Arbitrary_TxId: Arbitrary[TxId]

Attributes

Inherited from:
ArbitraryInstances

Attributes

Inherited from:
ArbitraryInstances
given given_Arbitrary_TxInfo: Arbitrary[TxInfo]

Attributes

Inherited from:
ArbitraryInstances
given given_Arbitrary_TxOut: Arbitrary[TxOut]

Attributes

Inherited from:
ArbitraryInstances

Attributes

Inherited from:
ArbitraryInstances
given given_Arbitrary_Value: Arbitrary[Value]

Attributes

Inherited from:
ArbitraryInstances

Attributes

Inherited from:
ArbitraryInstances
given given_Shrink_Data: Shrink[Data]

Attributes

Inherited from:
ArbitraryInstances
given given_Shrink_Program: Shrink[Program]

Attributes

Inherited from:
ArbitraryInstances
given iArb: Arbitrary[I]

Attributes

Inherited from:
ArbitraryInstances

Extensions

Inherited extensions

extension (self: SIR)
def runScript(using scalusOptions: Options = ...)(scriptContext: ScriptContext, param: Option[Data] = ...): Result

Attributes

Inherited from:
ScalusTest
def scriptV3(using scalusOptions: Options = ...)(errorTraces: Boolean = ...): Program

Attributes

Inherited from:
ScalusTest
extension (self: Program)

Attributes

Inherited from:
ScalusTest
def runWithDebug(scriptContext: ScriptContext): Result

Attributes

Inherited from:
ScalusTest