Currently, the test code generation imports kotlinx.coroutines.experimental.io.*, required by ByteReadChannel for all Ktor versions. From ktor 1.3.0 the API changed and ByteReadChannel is now located under io.ktor.utils.io.*. As a result, generated Ktor projects (version >= 1.3.0) using the Mock HttpClient Engine do not compile.
This PR addresses #27 and points ByteReadChannel to the correct import depending on the selected Ktor version.
Currently, the test code generation imports
kotlinx.coroutines.experimental.io.*
, required byByteReadChannel
for all Ktor versions. From ktor 1.3.0 the API changed andByteReadChannel
is now located underio.ktor.utils.io.*
. As a result, generated Ktor projects (version >= 1.3.0) using the Mock HttpClient Engine do not compile.This PR addresses #27 and points
ByteReadChannel
to the correct import depending on the selected Ktor version.