Spaces:
Sleeping
Sleeping
Commit
·
84875e8
1
Parent(s):
50c1399
Fixed test cases
Browse files- api/main.py +2 -1
- tests/test_api.py +1 -1
api/main.py
CHANGED
|
@@ -1,5 +1,5 @@
|
|
| 1 |
from fastapi import FastAPI
|
| 2 |
-
from .routers import orchestration, context_analysis, ideation , human_idea_refining , brainstorm , generate_final_story , generate_image
|
| 3 |
|
| 4 |
app = FastAPI()
|
| 5 |
|
|
@@ -9,6 +9,7 @@ async def root():
|
|
| 9 |
return {'response':'Hello'}
|
| 10 |
|
| 11 |
app.include_router(orchestration.router, prefix="/api")
|
|
|
|
| 12 |
app.include_router(context_analysis.router, prefix="/api")
|
| 13 |
app.include_router(ideation.router, prefix="/api")
|
| 14 |
app.include_router(human_idea_refining.router, prefix="/api")
|
|
|
|
| 1 |
from fastapi import FastAPI
|
| 2 |
+
from .routers import orchestration, context_analysis, ideation , human_idea_refining , brainstorm , generate_final_story , generate_image, show_analytics
|
| 3 |
|
| 4 |
app = FastAPI()
|
| 5 |
|
|
|
|
| 9 |
return {'response':'Hello'}
|
| 10 |
|
| 11 |
app.include_router(orchestration.router, prefix="/api")
|
| 12 |
+
app.include_router(show_analytics.router, prefix="/api")
|
| 13 |
app.include_router(context_analysis.router, prefix="/api")
|
| 14 |
app.include_router(ideation.router, prefix="/api")
|
| 15 |
app.include_router(human_idea_refining.router, prefix="/api")
|
tests/test_api.py
CHANGED
|
@@ -24,7 +24,7 @@ def test_orchestrator():
|
|
| 24 |
payload = {
|
| 25 |
"message":"Mention some popular influencers of nepal"
|
| 26 |
}
|
| 27 |
-
response = client.post("/api/
|
| 28 |
print(response.json())
|
| 29 |
assert response.status_code == 200
|
| 30 |
|
|
|
|
| 24 |
payload = {
|
| 25 |
"message":"Mention some popular influencers of nepal"
|
| 26 |
}
|
| 27 |
+
response = client.post("/api/orchestration", json=payload)
|
| 28 |
print(response.json())
|
| 29 |
assert response.status_code == 200
|
| 30 |
|