Mentions légales du service

Skip to content
Snippets Groups Projects
Commit 62d1b8ee authored by Ludovic Le Frioux's avatar Ludovic Le Frioux
Browse files

Add example of a get request to a server.

parent 2ba4a303
No related branches found
No related tags found
No related merge requests found
package client
import io.kotest.core.spec.style.StringSpec
import io.kotest.matchers.*
import io.ktor.client.*
import io.ktor.client.request.*
class CServiceTest : StringSpec({
"connect to express server" {
val client = HttpClient()
val result = client.get<String>("http://127.0.0.1:50000/")
result.shouldBe("Hello world!!")
}
})
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment