diff --git a/.github/test.py b/.github/test.py deleted file mode 100644 index 48459d7..0000000 --- a/.github/test.py +++ /dev/null @@ -1,31 +0,0 @@ -import sys -import os - -sys.path.insert(0, os.path.abspath(os.path.join(os.path.dirname(__file__), '..'))) - -from fastapi.testclient import TestClient -from app import app - -client = TestClient(app) - -def test_index(): - response = client.get("/") - assert response.status_code == 200 - assert "Schizo Bots" in response.text - assert '' in response.text - assert '' in response.text - -def test_new_chat(): - client.post("/pause") - - response = client.post("/new-chat") - assert response.status_code == 200 - assert response.json() == {"status": "new chat started"} - -def test_pause(): - response = client.post("/pause") - assert response.status_code == 200 - assert response.json()["paused"] is True - response = client.post("/pause") - assert response.status_code == 200 - assert response.json()["paused"] is False