public class TestApplicationResponse
Represents test call response received from server
| Constructor and Description |
|---|
TestApplicationResponse(TestApplicationCall call,
boolean readResponse)
Represents test call response received from server
|
| Modifier and Type | Method and Description |
|---|---|
NonExistentClass |
awaitWebSocket(java.time.Duration duration)
Wait for websocket session completion
|
kotlinx.coroutines.io.ByteReadChannel |
contentChannel()
Response body content channel
|
java.lang.Object |
flush(kotlin.coroutines.experimental.Continuation<? super kotlin.Unit> p)
Await for response job completion
|
byte[] |
getByteContent()
Response body byte content. Could be blocking
|
java.lang.String |
getContent()
Response body text content. Could be blocking.
|
kotlin.coroutines.CoroutineContext |
getCoroutineContext() |
io.ktor.response.ResponseHeaders |
getHeaders() |
boolean |
getReadResponse()
if response channel need to be consumed into byteContent
|
java.lang.Object |
respondUpgrade(io.ktor.http.content.OutgoingContent.ProtocolUpgrade upgrade,
kotlin.coroutines.experimental.Continuation<? super kotlin.Unit> p) |
java.lang.Object |
responseChannel(kotlin.coroutines.experimental.Continuation<? super kotlinx.coroutines.io.ByteWriteChannel> p) |
void |
setStatus(io.ktor.http.HttpStatusCode statusCode) |
kotlinx.coroutines.io.ByteReadChannel |
websocketChannel()
Websocket session's channel
|
public TestApplicationResponse(TestApplicationCall call, boolean readResponse)
Represents test call response received from server
readResponse - if response channel need to be consumed into byteContentpublic java.lang.String getContent()
Response body text content. Could be blocking.
public byte[] getByteContent()
Response body byte content. Could be blocking
public void setStatus(io.ktor.http.HttpStatusCode statusCode)
public io.ktor.response.ResponseHeaders getHeaders()
public java.lang.Object responseChannel(kotlin.coroutines.experimental.Continuation<? super kotlinx.coroutines.io.ByteWriteChannel> p)
public kotlinx.coroutines.io.ByteReadChannel contentChannel()
Response body content channel
public java.lang.Object flush(kotlin.coroutines.experimental.Continuation<? super kotlin.Unit> p)
Await for response job completion
public java.lang.Object respondUpgrade(io.ktor.http.content.OutgoingContent.ProtocolUpgrade upgrade,
kotlin.coroutines.experimental.Continuation<? super kotlin.Unit> p)
public NonExistentClass awaitWebSocket(java.time.Duration duration)
Wait for websocket session completion
public kotlinx.coroutines.io.ByteReadChannel websocketChannel()
Websocket session's channel
public boolean getReadResponse()
if response channel need to be consumed into byteContent
public kotlin.coroutines.CoroutineContext getCoroutineContext()