File size: 234 Bytes
583f6dd
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
from fastapi.testclient import TestClient
from api.main import root

client = TestClient(root)

def test_root():
    response = client.get("/")
    assert response.status_code == 200
    assert response.json() == {"response":"Hello"}