Make it FastAPI app
This commit is contained in:
parent
a017fd28a9
commit
eb1d04dbc3
5 changed files with 136 additions and 6 deletions
|
@ -1,6 +1,15 @@
|
|||
from fastapi.testclient import TestClient
|
||||
|
||||
from test_woodpecker.main import app
|
||||
|
||||
client = TestClient(app)
|
||||
|
||||
|
||||
def test_read_main():
|
||||
response = client.get("/")
|
||||
assert response.status_code == 200
|
||||
assert response.json()["msg"] == "Hello World"
|
||||
|
||||
|
||||
def test_ok():
|
||||
assert True
|
||||
|
||||
|
||||
def no_test_fail():
|
||||
assert False
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue