Expand description
The test client.
Requests go straight through the router โ no socket, no port, no waiting โ so an HTTP test costs about as much as calling a function:
โ
let client = TestClient::new(router);
client.get("/users").await.assert_ok().assert_see("Ada");Structsยง
- Test
Client - Test
Response - A response with assertions attached, each returning
selfso they chain.