mirror of
https://github.com/langbot-app/LangBot.git
synced 2026-06-09 15:26:03 +00:00
test: tighten phase 1 coverage contracts
This commit is contained in:
@@ -65,7 +65,8 @@ def fake_knowledge_app():
|
||||
# Auth services
|
||||
app.user_service = Mock()
|
||||
app.user_service.is_initialized = AsyncMock(return_value=True)
|
||||
app.user_service.verify_jwt_token = AsyncMock(return_value={'email': 'test@example.com'})
|
||||
app.user_service.verify_jwt_token = AsyncMock(return_value='test@example.com')
|
||||
app.user_service.get_user_by_email = AsyncMock(return_value=Mock(email='test@example.com'))
|
||||
app.apikey_service = Mock()
|
||||
app.apikey_service.verify_api_key = AsyncMock(return_value=True)
|
||||
|
||||
@@ -257,4 +258,4 @@ class TestKnowledgeBaseRetrieveEndpoint:
|
||||
|
||||
assert response.status_code == 400
|
||||
data = await response.get_json()
|
||||
assert data['code'] == -1
|
||||
assert data['code'] == -1
|
||||
|
||||
Reference in New Issue
Block a user