package kotlinx.coroutines.test.internal /* This is a declaration of JS's `Promise`. We need to keep it a separate class, because `actual typealias TestResult = Promise` fails: you can't instantiate an `expect class` with a typealias to a parametric class. So, we make a non-parametric class just for this. */ /** * @suppress */ @JsName("Promise") public external class JsPromiseInterfaceForTesting { /** * @suppress */ public fun then(onFulfilled: ((Unit) -> Unit), onRejected: ((Throwable) -> Unit)): JsPromiseInterfaceForTesting /** * @suppress */ public fun then(onFulfilled: ((Unit) -> Unit)): JsPromiseInterfaceForTesting }