File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed
app/src/test/java/com/lukaslechner/coroutineusecasesonandroid/utils Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -9,10 +9,12 @@ import kotlinx.coroutines.test.setMain
9
9
import org.junit.rules.TestWatcher
10
10
import org.junit.runner.Description
11
11
12
- // https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-test/
13
-
14
- // see: https://github.com/googlecodelabs/kotlin-coroutines/blob/master/coroutines-codelab/finished_code/src/test/java/com/example/android/kotlincoroutines/main/utils/MainCoroutineScopeRule.kt
15
-
12
+ /* *
13
+ * JUnit Rule that replaces the Main Dispatcher with a test dispatcher in your tests
14
+ *
15
+ * @see: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-test/
16
+ * @see: https://github.com/googlecodelabs/kotlin-coroutines/blob/master/coroutines-codelab/finished_code/src/test/java/com/example/android/kotlincoroutines/main/utils/MainCoroutineScopeRule.kt
17
+ */
16
18
@ExperimentalCoroutinesApi
17
19
class MainCoroutineScopeRule (
18
20
val testDispatcher : TestCoroutineDispatcher = TestCoroutineDispatcher ()
You can’t perform that action at this time.
0 commit comments