Spaces:
Runtime error
Runtime error
Download tests/test_main.py from mgbam/docappointemet: direct link, hf CLI and curl.
- Browser
- Download file 332 Bytes
-
https://huggingface.co/spaces/mgbam/docappointemet/resolve/1effb758119782258320f265603c7f36ef4b130c/tests/test_main.py
- Command line
-
hf download hf://spaces/mgbam/docappointemet@1effb758119782258320f265603c7f36ef4b130c/tests/test_main.py
-
curl -L -o test_main.py https://huggingface.co/spaces/mgbam/docappointemet/resolve/1effb758119782258320f265603c7f36ef4b130c/tests/test_main.py
332 Bytes
| import httpx | |
| from app.main import app # Assuming your FastAPI app instance is here | |
| def test_read_main(): | |
| """Tests that the root endpoint is reachable and returns a 200 OK status.""" | |
| with httpx.Client(app=app, base_url="http://test") as client: | |
| response = client.get("/") | |
| assert response.status_code == 200 |