AssertsVersionSpecific

utest.asserts.AssertsVersionSpecific

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
trait Asserts

Members list

Value members

Concrete methods

inline def assert(inline exprs: Boolean*): Unit

Checks that one or more expressions are true; otherwises raises an exception with some debugging info

Checks that one or more expressions are true; otherwises raises an exception with some debugging info

Attributes

inline def assertMatch(inline t: Any)(pf: => PartialFunction[Any, Unit]): Unit

Asserts that the given value matches the PartialFunction. Useful for using pattern matching to validate the shape of a data structure.

Asserts that the given value matches the PartialFunction. Useful for using pattern matching to validate the shape of a data structure.

Attributes

transparent inline def compileError(inline expr: String): CompileError

Asserts that the given expression fails to compile, and returns a utest.CompileError containing the message of the failure. If the expression compile successfully, this macro itself will raise a compilation error.

Asserts that the given expression fails to compile, and returns a utest.CompileError containing the message of the failure. If the expression compile successfully, this macro itself will raise a compilation error.

Attributes

inline def continually(inline exprs: Boolean*)(using ri: => RetryInterval, rm: => RetryMax): Unit

Checks that one or more expressions all remain true within a certain period of time. Polls at a regular interval to check this.

Checks that one or more expressions all remain true within a certain period of time. Polls at a regular interval to check this.

Attributes

inline def eventually(inline exprs: Boolean*)(using ri: => RetryInterval, rm: => RetryMax): Unit

Checks that one or more expressions all become true within a certain period of time. Polls at a regular interval to check this.

Checks that one or more expressions all become true within a certain period of time. Polls at a regular interval to check this.

Attributes

inline def intercept[T](inline exprs: Unit): T

Asserts that the given block raises the expected exception. The exception is returned if raised, and an AssertionError is raised if the expected exception does not appear.

Asserts that the given block raises the expected exception. The exception is returned if raised, and an AssertionError is raised if the expected exception does not appear.

Attributes