(client: TestClient)
| 310 | |
| 311 | |
| 312 | def test_router_query_method(client: TestClient) -> None: |
| 313 | response = client.request("QUERY", "/search") |
| 314 | assert response.status_code == 200 |
| 315 | assert response.text == "Hello, QUERY!" |
| 316 | |
| 317 | response = client.get("/search") |
| 318 | assert response.status_code == 405 |
| 319 | assert response.text == "Method Not Allowed" |
| 320 | assert response.headers["allow"] == "QUERY" |
| 321 | |
| 322 | |
| 323 | def test_router_add_websocket_route(client: TestClient) -> None: |