androidx.work.testing
Interfaces
TestDriver |
Additional functionality exposed for |
Classes
SynchronousExecutor |
Is an implementation of a |
TestListenableWorkerBuilder |
Builds instances of |
TestWorkerBuilder |
Builds instances of |
WorkManagerTestInitHelper |
Helps initialize |
Top-level functions summary
TestListenableWorkerBuilder<W> |
TestListenableWorkerBuilder(context: Context, inputData: Data = Data.EMPTY, tags: List<String> = emptyList(), runAttemptCount: Int = 1, triggeredContentUris: List<Uri> = emptyList(), triggeredContentAuthorities: List<String> = emptyList()) Builds an instance of TestListenableWorkerBuilder. |
TestWorkerBuilder<W> |
TestWorkerBuilder(context: Context, executor: Executor, inputData: Data = Data.EMPTY, tags: List<String> = emptyList(), runAttemptCount: Int = 1, triggeredContentUris: List<Uri> = emptyList(), triggeredContentAuthorities: List<String> = emptyList()) Builds an instance of TestWorkerBuilder. |
Top-level functions
TestListenableWorkerBuilder
inline fun <reified W : ListenableWorker> TestListenableWorkerBuilder(
context: Context,
inputData: Data = Data.EMPTY,
tags: List<String> = emptyList(),
runAttemptCount: Int = 1,
triggeredContentUris: List<Uri> = emptyList(),
triggeredContentAuthorities: List<String> = emptyList()
): TestListenableWorkerBuilder<W>
Builds an instance of TestListenableWorkerBuilder.
Parameters | |
---|---|
W |
The subtype of ListenableWorker |
context: Context | The application Context |
inputData: Data = Data.EMPTY | The input data for the ListenableWorker |
runAttemptCount: Int = 1 | The run attempt count of the ListenableWorker |
triggeredContentUris: List<Uri> = emptyList() | The list of triggered content Uris |
triggeredContentAuthorities: List<String> = emptyList() | The list of triggered content authorities |
Return | |
---|---|
The instance of | TestListenableWorkerBuilder |
TestWorkerBuilder
inline fun <reified W : Worker> TestWorkerBuilder(
context: Context,
executor: Executor,
inputData: Data = Data.EMPTY,
tags: List<String> = emptyList(),
runAttemptCount: Int = 1,
triggeredContentUris: List<Uri> = emptyList(),
triggeredContentAuthorities: List<String> = emptyList()
): TestWorkerBuilder<W>
Builds an instance of TestWorkerBuilder.
Parameters | |
---|---|
W |
The subtype of Worker |
context: Context | The application Context |
executor: Executor | The Executor that the Worker runs on |
inputData: Data = Data.EMPTY | The input data for the Worker |
runAttemptCount: Int = 1 | The run attempt count of the Worker |
triggeredContentUris: List<Uri> = emptyList() | The list of triggered content Uris |
triggeredContentAuthorities: List<String> = emptyList() | The list of triggered content authorities |
Return | |
---|---|
The instance of | TestWorkerBuilder |