SpecificationError

scalus.cardano.onchain.SpecificationError
class SpecificationError(msg: String) extends AssertionError

A specification written with scalus.cardano.onchain.plutus.prelude.Spec does not hold. It is thrown off-chain only: a compiled script carries no specification.

So it is no OnchainError, which stands off-chain for a script that fails. A test that expects the script to reject a transaction does not pass because a specification was violated: the script, without the specification, may accept it. It is an AssertionError, as the one Predef.ensuring throws: what is wrong is the code or its caller, not the transaction.

Attributes

Graph
Supertypes
class AssertionError
class Error
class Throwable
trait Serializable
class Object
trait Matchable
class Any
Show all

Members list

Value members

Inherited methods

final def addSuppressed(x$0: Throwable): Unit

Attributes

Inherited from:
Throwable
def fillInStackTrace(): Throwable

Attributes

Inherited from:
Throwable
def getCause(): Throwable

Attributes

Inherited from:
Throwable
def getLocalizedMessage(): String

Attributes

Inherited from:
Throwable
def getMessage(): String

Attributes

Inherited from:
Throwable
def getStackTrace(): Array[StackTraceElement]

Attributes

Inherited from:
Throwable
final def getSuppressed(): Array[Throwable]

Attributes

Inherited from:
Throwable
def initCause(x$0: Throwable): Throwable

Attributes

Inherited from:
Throwable
def printStackTrace(x$0: PrintWriter): Unit

Attributes

Inherited from:
Throwable
def printStackTrace(x$0: PrintStream): Unit

Attributes

Inherited from:
Throwable
def printStackTrace(): Unit

Attributes

Inherited from:
Throwable
def setStackTrace(x$0: Array[StackTraceElement]): Unit

Attributes

Inherited from:
Throwable
def toString(): String

Returns a string representation of the object.

Returns a string representation of the object.

The default representation is platform dependent.

Attributes

Returns

a string representation of the object.

Inherited from:
Throwable