object TestAspect extends TimeoutVariants
- Alphabetic
- By Inheritance
- TestAspect
- TimeoutVariants
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Type Members
- trait PerTest[+LowerR, -UpperR, +LowerE, -UpperE, +LowerS, -UpperS] extends TestAspect[LowerR, UpperR, LowerE, UpperE, LowerS, UpperS]
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
after[R0, E0](effect: ZIO[R0, E0, Any]): TestAspect[Nothing, R0, E0, Any, Nothing, Any]
Constructs an aspect that runs the specified effect after every test.
-
def
around[R0, E0](before: ZIO[R0, E0, Any], after: ZIO[R0, Nothing, Any]): PerTest[Nothing, R0, E0, Any, Nothing, Any]
Constructs an aspect that evaluates every test inside the context of a
Managed. -
def
aroundTest[R0, E0, S0](managed: ZManaged[R0, TestFailure[E0], (TestSuccess[S0]) ⇒ ZIO[R0, TestFailure[E0], TestSuccess[S0]]]): PerTest[Nothing, R0, E0, Any, S0, S0]
Constructs an aspect that evaluates every test inside the context of the managed function.
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
aspect[R0, E0, S0](f: (ZIO[R0, TestFailure[E0], TestSuccess[S0]]) ⇒ ZIO[R0, TestFailure[E0], TestSuccess[S0]]): TestAspect[R0, R0, E0, E0, S0, S0]
Constucts a simple monomorphic aspect that only works with the specified environment and error type.
-
def
before[R0, E0, S0](effect: ZIO[R0, Nothing, Any]): TestAspect[Nothing, R0, E0, Any, S0, Any]
Constructs an aspect that runs the specified effect before every test.
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
def
dotty[LowerR, UpperR, LowerE, UpperE, LowerS, UpperS](that: TestAspect[LowerR, UpperR, LowerE, UpperE, LowerS, UpperS]): TestAspect[LowerR, UpperR, LowerE, UpperE, LowerS, UpperS]
An aspect that applies the specified aspect on Dotty.
-
val
dottyOnly: TestAspectPoly
An aspect that only runs tests on Dotty.
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
val
eventually: TestAspectPoly
An aspect that retries a test until success, without limit.
-
val
exceptDotty: TestAspectPoly
An aspect that runs tests on all versions except Dotty.
-
val
exceptJS: TestAspectPoly
An aspect that runs tests on all platforms except ScalaJS.
-
val
exceptJVM: TestAspectPoly
An aspect that runs tests on all platforms except the JVM.
-
val
exceptScala2: TestAspectPoly
An aspect that runs tests on all versions except Scala2.
-
def
executionStrategy(exec: ExecutionStrategy): TestAspectPoly
An aspect that sets suites to the specified execution strategy, but only if their current strategy is inherited (undefined).
-
def
failure[E0](p: Assertion[TestFailure[E0]]): PerTest[Nothing, Any, Nothing, E0, Unit, Unit]
An aspect that makes a test that failed for the specified failure pass.
An aspect that makes a test that failed for the specified failure pass. Note that the test will fail for other failures and also if it passes correctly.
-
val
failure: PerTest[Nothing, Any, Nothing, Any, Unit, Unit]
An aspect that makes a test that failed for any reason pass.
An aspect that makes a test that failed for any reason pass. Note that if the test passes this aspect will make it fail.
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
def
flaky(n: Int): TestAspectPoly
An aspect that retries a test until success, with the specified limit, for use with flaky tests.
-
val
flaky: TestAspectPoly
An aspect that retries a test until success, with a default limit, for use with flaky tests.
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
val
identity: TestAspectPoly
An aspect that returns the tests unchanged
-
def
ifEnv(env: String, assertion: Assertion[String]): TestAspect[Nothing, Live[System], Nothing, Any, Nothing, Any]
An aspect that only runs a test if the specified environment variable satisfies the specified assertion.
-
def
ifEnvSet(env: String): TestAspect[Nothing, Live[System], Nothing, Any, Nothing, Any]
As aspect that only runs a test if the specified environment variable is set.
-
def
ifProp(prop: String, assertion: Assertion[String]): TestAspect[Nothing, Live[System], Nothing, Any, Nothing, Any]
An aspect that only runs a test if the specified Java property satisfies the specified assertion.
-
def
ifPropSet(prop: String): TestAspect[Nothing, Live[System], Nothing, Any, Nothing, Any]
As aspect that only runs a test if the specified Java property is set.
-
val
ignore: TestAspectPoly
An aspect that marks tests as ignored.
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
def
js[LowerR, UpperR, LowerE, UpperE, LowerS, UpperS](that: TestAspect[LowerR, UpperR, LowerE, UpperE, LowerS, UpperS]): TestAspect[LowerR, UpperR, LowerE, UpperE, LowerS, UpperS]
An aspect that applies the specified aspect on ScalaJS.
-
val
jsOnly: TestAspectPoly
An aspect that only runs tests on ScalaJS.
-
def
jvm[LowerR, UpperR, LowerE, UpperE, LowerS, UpperS](that: TestAspect[LowerR, UpperR, LowerE, UpperE, LowerS, UpperS]): TestAspect[LowerR, UpperR, LowerE, UpperE, LowerS, UpperS]
An aspect that applies the specified aspect on the JVM.
-
val
jvmOnly: TestAspectPoly
An aspect that only runs tests on the JVM.
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
nonFlaky(n: Int): TestAspectPoly
An aspect that repeats the test a specified number of times, ensuring it is stable ("non-flaky").
An aspect that repeats the test a specified number of times, ensuring it is stable ("non-flaky"). Stops at the first failure.
-
val
nonFlaky: TestAspectPoly
An aspect that repeats the test a default number of times, ensuring it is stable ("non-flaky").
An aspect that repeats the test a default number of times, ensuring it is stable ("non-flaky"). Stops at the first failure.
-
def
nonFlakyPar(n: Int): TestAspectPoly
An aspect that runs the test a specified number of times in parallel, ensuring it is stable ("non-flaky").
An aspect that runs the test a specified number of times in parallel, ensuring it is stable ("non-flaky"). Stops at the first failure. This can be useful for testing effects during periods of high contention.
-
val
nonFlakyPar: TestAspectPoly
An aspect that runs the test a default number of times in parallel, ensuring it is stable ("non-flaky").
An aspect that runs the test a default number of times in parallel, ensuring it is stable ("non-flaky"). Stops at the first failure. This can be useful for testing effects during periods of high contention.
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
val
parallel: TestAspectPoly
An aspect that executes the members of a suite in parallel.
-
def
parallelN(n: Int): TestAspectPoly
An aspect that executes the members of a suite in parallel, up to the specified number of concurrent fibers.
-
def
retry[R0, E0, S0](schedule: Schedule[R0, TestFailure[E0], S0]): TestAspect[Nothing, R0, Nothing, E0, Nothing, Any]
An aspect that retries failed tests according to a schedule.
-
def
scala2[LowerR, UpperR, LowerE, UpperE, LowerS, UpperS](that: TestAspect[LowerR, UpperR, LowerE, UpperE, LowerS, UpperS]): TestAspect[LowerR, UpperR, LowerE, UpperE, LowerS, UpperS]
An aspect that applies the specified aspect on Scala 2.
-
val
scala2Only: TestAspectPoly
An aspect that only runs tests on Scala 2.
-
val
sequential: TestAspectPoly
An aspect that executes the members of a suite sequentially.
-
val
success: TestAspectPoly
An aspect that converts ignored tests into test failures.
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
timeout(duration: Duration, interruptDuration: Duration = 1.second): TestAspect[Nothing, Live[Clock], Nothing, Any, Nothing, Any]
An aspect that times out tests using the specified duration.
An aspect that times out tests using the specified duration.
- duration
maximum test duration
- interruptDuration
after test timeout will wait given duration for successful interruption
-
def
timeoutWarning(duration: Duration): TestAspect[Nothing, Live[Clock] with Live[Console], Nothing, Any, Nothing, Any]
A test aspect that prints a warning to the console when a test takes longer than the specified duration.
A test aspect that prints a warning to the console when a test takes longer than the specified duration.
- Definition Classes
- TimeoutVariants
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()