1 /* 2 * Copyright 2016-2019 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license. 3 */ 4 5 package kotlinx.coroutines.rx2 6 7 import io.reactivex.* 8 import kotlinx.coroutines.flow.* 9 import org.junit.* 10 import org.reactivestreams.* 11 import org.reactivestreams.tck.* 12 13 class IterableFlowAsFlowableTckTest : PublisherVerification<Long>(TestEnvironment()) { 14 generatenull15 private fun generate(num: Long): Array<Long> { 16 return Array(if (num >= Integer.MAX_VALUE) 1000000 else num.toInt()) { it.toLong() } 17 } 18 createPublishernull19 override fun createPublisher(elements: Long): Flowable<Long> { 20 return generate(elements).asIterable().asFlow().asFlowable() 21 } 22 createFailedPublishernull23 override fun createFailedPublisher(): Publisher<Long>? = null 24 25 @Ignore 26 override fun required_spec309_requestZeroMustSignalIllegalArgumentException() { 27 } 28 29 @Ignore required_spec309_requestNegativeNumberMustSignalIllegalArgumentExceptionnull30 override fun required_spec309_requestNegativeNumberMustSignalIllegalArgumentException() { 31 } 32 33 @Ignore required_spec312_cancelMustMakeThePublisherToEventuallyStopSignalingnull34 override fun required_spec312_cancelMustMakeThePublisherToEventuallyStopSignaling() { 35 // 36 } 37 } 38