From 9e609e38f54c8a283554f6cd525e357c946d35f5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?M=C3=A1rton=20Braun?= Date: Mon, 21 Feb 2022 17:29:07 +0100 Subject: [PATCH 1/2] Add references to available implementations in TestDispatcher docs --- kotlinx-coroutines-test/common/src/TestDispatcher.kt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/kotlinx-coroutines-test/common/src/TestDispatcher.kt b/kotlinx-coroutines-test/common/src/TestDispatcher.kt index 3b756b19e9..631ac63a0d 100644 --- a/kotlinx-coroutines-test/common/src/TestDispatcher.kt +++ b/kotlinx-coroutines-test/common/src/TestDispatcher.kt @@ -10,6 +10,9 @@ import kotlin.jvm.* /** * A test dispatcher that can interface with a [TestCoroutineScheduler]. + * + * @see StandardTestDispatcher A predictable, controllable dispatcher. + * @see UnconfinedTestDispatcher A dispatcher that is not confined to any particular thread. */ @ExperimentalCoroutinesApi public abstract class TestDispatcher internal constructor(): CoroutineDispatcher(), Delay { From a6f8805b0508c67145b220a6f4ca290441e56172 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?M=C3=A1rton=20Braun?= Date: Thu, 17 Mar 2022 09:29:43 +0100 Subject: [PATCH 2/2] Update kotlinx-coroutines-test/common/src/TestDispatcher.kt Co-authored-by: dkhalanskyjb <52952525+dkhalanskyjb@users.noreply.github.com> --- kotlinx-coroutines-test/common/src/TestDispatcher.kt | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/kotlinx-coroutines-test/common/src/TestDispatcher.kt b/kotlinx-coroutines-test/common/src/TestDispatcher.kt index 631ac63a0d..f434572663 100644 --- a/kotlinx-coroutines-test/common/src/TestDispatcher.kt +++ b/kotlinx-coroutines-test/common/src/TestDispatcher.kt @@ -11,8 +11,10 @@ import kotlin.jvm.* /** * A test dispatcher that can interface with a [TestCoroutineScheduler]. * - * @see StandardTestDispatcher A predictable, controllable dispatcher. - * @see UnconfinedTestDispatcher A dispatcher that is not confined to any particular thread. + * The available implementations are: + * * [StandardTestDispatcher] is a dispatcher that places new tasks into a queue. + * * [UnconfinedTestDispatcher] is a dispatcher that behaves like [Dispatchers.Unconfined] while allowing to control + * the virtual time. */ @ExperimentalCoroutinesApi public abstract class TestDispatcher internal constructor(): CoroutineDispatcher(), Delay {