Test Results - CBIndex¶
Test suite execution results for CBIndex v0.3.1.
Last Run: 2026-01-23 Python: 3.12.9 Platform: Linux
Summary¶
| Metric | Value |
|---|---|
| Total Tests | 81 |
| Passed | 81 |
| Failed | 0 |
| Duration | 0.90s |
| Warnings | 239 (deprecation) |
Test Modules¶
test_ai_provider.py (10 tests)¶
Tests for the Nominate AI provider abstraction layer.
| Test | Status |
|---|---|
test_initialization |
PASSED |
test_api_url_trailing_slash_removed |
PASSED |
test_get_headers |
PASSED |
test_build_messages_without_history |
PASSED |
test_build_messages_with_history |
PASSED |
test_build_payload |
PASSED |
test_chat_success |
PASSED |
test_chat_async_success |
PASSED |
test_chat_with_finish_reason |
PASSED |
test_chat_with_max_tokens_finish_reason |
PASSED |
test_api_endpoints.py (18 tests)¶
Tests for FastAPI endpoint routing and authentication.
| Test | Status |
|---|---|
test_health_check |
PASSED |
test_health_check_no_auth_required |
PASSED |
test_index_pdf_requires_auth |
PASSED |
test_index_markdown_requires_auth |
PASSED |
test_workspaces_require_auth |
PASSED |
test_ocr_requires_auth |
PASSED |
test_intel_requires_auth |
PASSED |
test_create_workspace |
PASSED |
test_list_workspaces |
PASSED |
test_get_workspace |
PASSED |
test_get_nonexistent_workspace |
PASSED |
test_delete_workspace |
PASSED |
test_upload_file_to_workspace |
PASSED |
test_list_files_in_workspace |
PASSED |
test_delete_file_from_workspace |
PASSED |
test_pdf_endpoint_rejects_non_pdf |
PASSED |
test_markdown_endpoint_rejects_both_file_and_content |
PASSED |
test_markdown_endpoint_requires_input |
PASSED |
test_chat.py (32 tests)¶
Tests for conversation and chat functionality.
| Test | Status |
|---|---|
test_save_and_get_index |
PASSED |
test_list_indexes |
PASSED |
test_delete_index |
PASSED |
test_node_counting |
PASSED |
test_create_conversation |
PASSED |
test_get_conversation |
PASSED |
test_add_message |
PASSED |
test_list_conversations |
PASSED |
test_delete_conversation |
PASSED |
test_generate_title_from_query |
PASSED |
test_document_index_model |
PASSED |
test_message_model |
PASSED |
test_conversation_model |
PASSED |
test_node_reference_model |
PASSED |
test_list_indexes_empty |
PASSED |
test_list_conversations_empty |
PASSED |
test_create_conversation |
PASSED |
test_get_conversation |
PASSED |
test_get_nonexistent_conversation |
PASSED |
test_delete_conversation |
PASSED |
test_get_index_not_found |
PASSED |
test_workspace_not_found |
PASSED |
test_authentication_required |
PASSED |
test_create_conversation_with_document_scope |
PASSED |
test_create_conversation_default_title |
PASSED |
test_list_multiple_conversations |
PASSED |
test_delete_index_not_found |
PASSED |
test_delete_conversation_not_found |
PASSED |
test_query_requires_workspace |
PASSED |
test_query_requires_auth |
PASSED |
test_conversation_messages_structure |
PASSED |
test_index_list_response_structure |
PASSED |
test_ocr.py (9 tests)¶
Tests for OCR service and text conversion.
| Test | Status |
|---|---|
test_basic_conversion |
PASSED |
test_multiple_paragraphs |
PASSED |
test_empty_text |
PASSED |
test_initialization_with_settings |
PASSED |
test_initialization_with_explicit_values |
PASSED |
test_ocr_from_url_success |
PASSED |
test_ocr_from_base64_success |
PASSED |
test_ocr_from_file_uses_base64 |
PASSED |
test_workspace.py (12 tests)¶
Tests for workspace storage and file management.
| Test | Status |
|---|---|
test_sanitize_filename |
PASSED |
test_detect_file_type |
PASSED |
test_compute_file_hash |
PASSED |
test_generate_stored_filename |
PASSED |
test_create_workspace |
PASSED |
test_store_and_read_file |
PASSED |
test_delete_workspace |
PASSED |
test_list_workspaces |
PASSED |
test_create_workspace |
PASSED |
test_upload_file |
PASSED |
test_upload_duplicate_file |
PASSED |
test_delete_file |
PASSED |
test_get_or_create_workspace |
PASSED |
Deprecation Warnings¶
The following deprecation warnings were observed (non-blocking):
| Warning | Location | Recommendation |
|---|---|---|
datetime.utcnow() deprecated |
app/workspace/storage.py:95 |
Use datetime.now(datetime.UTC) |
datetime.utcnow() deprecated |
app/chat/index_storage.py:92 |
Use datetime.now(datetime.UTC) |
datetime.utcnow() deprecated |
app/chat/conversation_storage.py:70,113 |
Use datetime.now(datetime.UTC) |
PyPDF2 deprecated |
External dependency | Consider migrating to pypdf |