• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright 2016-2021 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license.
3  */
4 
5 package kotlinx.coroutines.reactive
6 
7 import kotlinx.coroutines.*
8 import kotlinx.coroutines.flow.*
9 import org.junit.*
10 
11 
12 class CancelledParentAttachTest : TestBase() {;
13 
14     @Test
<lambda>null15     fun testFlow() = runTest {
16         val f = flowOf(1, 2, 3).cancellable()
17         val j = Job().also { it.cancel() }
18         f.asPublisher(j).asFlow().collect()
19     }
20 
21 }
22