Minor. Fix tests after CoroutineContext introduction

This commit is contained in:
Denis Zharkov
2017-01-14 13:15:18 +03:00
parent 6a1ad3a279
commit c7f76d7ec8
5 changed files with 42 additions and 6 deletions
+2
View File
@@ -48,6 +48,8 @@ fun box(): String {
fun <T> async(c: suspend () -> T): CompletableFuture<T> {
val future = CompletableFuture<T>()
c.startCoroutine(object : Continuation<T> {
override val context = EmptyCoroutineContext
override fun resume(data: T) {
future.complete(data)
}
+2
View File
@@ -45,6 +45,8 @@ fun box(): String {
fun <T> async(c: suspend () -> T): CompletableFuture<T> {
val future = CompletableFuture<T>()
c.startCoroutine(object : Continuation<T> {
override val context = EmptyCoroutineContext
override fun resume(data: T) {
future.complete(data)
}