# feat: Add kotlin-sdk-testing module with channel-based transport implementation - Introduced `kotlin-sdk-testing` module for testing utilities in the MCP Kotlin SDK. - Implemented `ChannelTransport`, providing JSON-RPC transport via Kotlin coroutines channels. <!-- Provide a brief summary of your changes --> ## Motivation and Context This ChannelTransport can be used for testing Server implementation without using real transports. ## How Has This Been Tested? Unit test ## Breaking Changes No ## Types of changes - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to change) - [x] Documentation update ## Checklist <!-- Go over all the following points, and put an `x` in all the boxes that apply. --> - [x] I have read the [MCP Documentation](https://modelcontextprotocol.io) - [x] My code follows the repository's style guidelines - [x] New and existing tests pass locally - [x] I have added appropriate error handling - [x] I have added or updated documentation as needed
37 lines
1.2 KiB
Kotlin
37 lines
1.2 KiB
Kotlin
plugins {
|
|
id("mcp.multiplatform")
|
|
}
|
|
|
|
kotlin {
|
|
jvm {
|
|
tasks.withType<Test> {
|
|
useJUnitPlatform()
|
|
}
|
|
}
|
|
sourceSets {
|
|
commonTest {
|
|
dependencies {
|
|
implementation(project(":kotlin-sdk"))
|
|
implementation(kotlin("test"))
|
|
implementation(libs.kotest.assertions.core)
|
|
implementation(libs.kotest.assertions.json)
|
|
implementation(libs.kotlin.logging)
|
|
implementation(libs.kotlinx.coroutines.test)
|
|
implementation(libs.ktor.client.cio)
|
|
implementation(libs.ktor.server.cio)
|
|
implementation(libs.ktor.server.content.negotiation)
|
|
implementation(libs.ktor.serialization)
|
|
implementation(libs.ktor.server.websockets)
|
|
implementation(libs.ktor.server.test.host)
|
|
implementation(libs.ktor.server.content.negotiation)
|
|
implementation(libs.ktor.serialization)
|
|
}
|
|
}
|
|
jvmTest {
|
|
dependencies {
|
|
implementation(project(":test-utils"))
|
|
implementation(project(":kotlin-sdk-testing"))
|
|
}
|
|
}
|
|
}
|
|
}
|