Skip to content

test(memory): add integration tests for store_session_summary → Qdrant upsert roundtrip#1936

Merged
bug-ops merged 3 commits intomainfrom
test-memory-add-integration-te
Mar 16, 2026
Merged

test(memory): add integration tests for store_session_summary → Qdrant upsert roundtrip#1936
bug-ops merged 3 commits intomainfrom
test-memory-add-integration-te

Conversation

@bug-ops
Copy link
Copy Markdown
Owner

@bug-ops bug-ops commented Mar 16, 2026

Summary

Closes #1916

  • Add 4 #[ignore] integration tests to crates/zeph-memory/tests/qdrant_integration.rs using testcontainers (real Qdrant) to verify the full store_session_summary → Qdrant upsert roundtrip that was previously completely untested
  • Add setup_semantic_memory_with_qdrant() helper: real Qdrant via testcontainers, SQLite :memory:, MockProvider with fixed 384-dim embedding
  • Each test guards against silent Qdrant=None construction via has_vector_store() + is_vector_store_connected() assertions

Tests added

Test Verifies
store_session_summary_roundtrip Store one summary, search it back, verify summary_text, conversation_id, score ≈ 1.0
store_session_summary_multiple_conversations 3 conversations: unfiltered count=3, filter by exclusion removes correct ID, remaining two IDs present
store_shutdown_summary_full_roundtrip SQLite path (has_session_summary + content via load_summaries) AND Qdrant vector search path
search_session_summaries_returns_empty_when_no_data Empty collection returns Ok(vec![]), not an error

Test plan

  • All 4 new integration tests pass against real Qdrant via Docker (cargo nextest run -p zeph-memory -- --ignored)
  • 6053 unit tests pass, no regressions
  • cargo +nightly fmt --check clean
  • cargo clippy --workspace --features full -- -D warnings clean

bug-ops added 2 commits March 16, 2026 23:10
…t roundtrip (#1916)

Add four #[ignore] integration tests to crates/zeph-memory/tests/qdrant_integration.rs
using testcontainers (real Qdrant) and SQLite :memory::

- store_session_summary_roundtrip: stores one summary, searches it back,
  verifies summary_text, conversation_id, and score (epsilon for f32 rounding)
- store_session_summary_multiple_conversations: stores 3 summaries, verifies
  unfiltered count=3, filtered exclusion removes correct conversation, and
  remaining two conversation IDs are present
- store_shutdown_summary_full_roundtrip: verifies both the SQLite path
  (has_session_summary + content via load_summaries) and the Qdrant path
  (vector search returns the stored summary)
- search_session_summaries_returns_empty_when_no_data: verifies Ok(vec![])
  on empty collection, not an error

Each test guards against silent Qdrant=None construction via has_vector_store()
and is_vector_store_connected() assertions. New helper
setup_semantic_memory_with_qdrant() provides real Qdrant + SQLite :memory: +
MockProvider with fixed 384-dim embedding.

Closes #1916
@github-actions github-actions bot added tests Test-related changes documentation Improvements or additions to documentation memory zeph-memory crate (SQLite) rust Rust code changes size/M Medium PR (51-200 lines) and removed tests Test-related changes labels Mar 16, 2026
@bug-ops bug-ops enabled auto-merge (squash) March 16, 2026 22:11
@github-actions github-actions bot added the tests Test-related changes label Mar 16, 2026
@bug-ops bug-ops merged commit ff40334 into main Mar 16, 2026
20 checks passed
@bug-ops bug-ops deleted the test-memory-add-integration-te branch March 16, 2026 22:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation memory zeph-memory crate (SQLite) rust Rust code changes size/M Medium PR (51-200 lines) tests Test-related changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

test(memory): add integration test for store_session_summary → Qdrant upsert roundtrip

1 participant