//Extensions for Jetpack Lifecycle/it.czerwinski.android.lifecycle.livedata.test.junit5/InstantTaskExecutorExtension

InstantTaskExecutorExtension

[androidJvm] class InstantTaskExecutorExtension : InstantTaskExecutorRule, BeforeEachCallback, AfterEachCallback

JUnit5 extension that swaps the background executor used by the Architecture Components with a different one which executes each task synchronously.

This extension is analogous to InstantTaskExecutorRule for JUnit4.

Constructors

   
InstantTaskExecutorExtension [androidJvm] fun InstantTaskExecutorExtension()

Functions

Name Summary
afterEach [androidJvm]
Content
open override fun afterEach(context: ExtensionContext?)


apply [androidJvm]
Content
open override fun apply(p0: Statement, p1: Description): Statement


beforeEach [androidJvm]
Content
open override fun beforeEach(context: ExtensionContext?)


failed [androidJvm]
Content
open fun failed(p0: Throwable, p1: Description)


finished [androidJvm]
Content
open override fun finished(p0: Description)


skipped [androidJvm]
Content
open fun skipped(p0: AssumptionViolatedException, p1: Description)
open fun skipped(p0: AssumptionViolatedException, p1: Description)


starting [androidJvm]
Content
open override fun starting(p0: Description)


succeeded [androidJvm]
Content
open fun succeeded(p0: Description)